If they're old enough (5-6+), wait for a quiet moment and discuss the issue with them. Explain why you can't allow that sort of behaviour, even when they're very angry.
Respect for everyone is essential in life and if you don't respect others, day-to-day life can become unbearable. Give them examples: what would happen if everyone fought or started trading insults for the slightest thing and everyone acted just as they wanted to? Don't be afraid to emphasise this so that they understand what you mean and give relevant examples: OK, so if everyone came to blows over little trifles, the world would grind to a halt, but what would happen if their teachers started arguing and shouting at each other whenever they got annoyed?