Urgh. This is the tough time. My boys had it at age 7/8.
Told them that life "isn't fair" and they can't always have it "THEIR WAY", life isn't a dictatorship. Told them to LISTEN to their friends and ask what rules they wanted to use and see if there was a compromise that could be made. Otherwise he would be friendless because NOONE wants a "sore loser" nor do they want someone who ONLY wants to play by THEIR OWN rules....
We didn't allow our boys to "quit" either. they had to stick it out. For whatever reason - baseball, soccer, lacrosse, swimming, tae kwon do, etc. they had to stick it out for the season and continue to do their best. Kind like food - they have to try it before they say they don't like it. when we paid for sports? made them stick out the season because they could always learn something from it.
He's not going to learn how to treat people if you keep them away. however, THEY may NOT want to come over because of HOW HE treats them. He needs to understand that FRIENDS need him to listen to their wishes too, it's not all about him.
Good luck!