This behavior is called allogrooming.
Purposes
Hygiene: Removes parasites and debris.
Social bonding: Strengthens relationships and group cohesion.
Stress relief: A relaxing activity.
Conflict resolution: Can appease dominant individuals or repair relationships after fights.
Allogrooming is common among monkeys and other primates.