In primates, the group size correlates with brain size. In other mammals and birds this is not the case.

Machu Picchu, Peru
There, however, it is apparent that the monogamous species (in pairs) have a larger brain than the polygamous species. Dunbar’s interpretation of this finding is,
that the original incentive for the evolution of larger brains can be found in the development of bonding in couples, which usually goes hand in hand with the fact that both parents care for the offspring (…)
We can imagine that in the event that when pair bonding became an established practice, it led to larger brains and the cognitive ability to deal with complex relationships (relations). Primates have succeeded in exploiting these cognitive abilities by generalising them so that they would be available to all members of social groups. (pp. 249s)
So with the larger brain, which was developed through pair bonding, more complex social systems could be mastered with friends i.e. with non-reproductive partners.