If the force exerted by the left team on the right team  equals the force exerted by the right team on the left team, how can any team ever win a tug of war?

The forces the teams exert on one another have nothing to do with who wins! The team that wins is the team that can exert the largest forward force on the ground; the ground then exerts an equal and opposite force backward on that team. We would have something like

mLa = FgL - T,
mRa = - FgR + T,

so that, adding,

[mL+ mR]a = FgL - FgR.