Per @unknown's comment on MC-46956, I'm making a new report for this.
When mobs are on teams they can be hit by projectiles from teammates, unlike players.
Steps to reproduce:
/team add TestTeam
/team modify TestTeam friendlyFire false
run a few times:
/summon skeleton ~ ~ ~ {Team:TestTeam,HandItems:[{id:bow,Count:1}]}
get the skeletons to attack you
notice how some of the skeletons take damage from other skeletons' arrows.
Expected result:
Friendly fire is respected and the mobs be hit by teammates' projectiles.
Affects all forms of non-melee damage, so arrows, fireballs, dragon breath, splash potions, evocation fangs, etc.
I can confirm this behavior.