I said it before and will say it again: the way public high schools are arranged is cruel towards both the kids and the adults. (Also counterproductive, but first of all, cruel.)
Teenagers are forced into groups of the same age, within 1 year tolerance. This is the age of learning of social structures, building social ties, learning about various forms of social status, etc. They need to be inside a rich social structure to learn all that.
Instead, they are locked up with their peers, and a lonely adult. What can they do?
Of course they try to build various social structures of themselves, but since they are all peers in most regards, the only structure they can build is a gang. The more bold (and often violent) becomes a leader, others follow.
The only way to raise in status is to join a gang, and fight for a higher rung, or to start a gang. The more violent gang leaders do everything to make actual learning seen as despicable, because they'd hate to see a competing hierarchy based on academic success. Confronting the lone adult, a dangerous but not too dangerous enterprise, becomes a way to show bravery to others.
While some students may cause more problems and be more prone to violence than others, the cause is not the presence of such students, like presence of oil is not a cause of a fire. It's the system, the way classes are formed, that ignites them.
BTW 100-150 years ago high school was elective and required certain determination to get into it. This is why it did not show these problems so much: the students joined because they valued the academic success hierarchy, and could form structures along attaining better grades at the very least. (A teacher had many more violent response options, too.) But today's public high schools receive students with different incentives, even filtered against attaining academic success, because kids who eagerly want to learn go to various competitive high schools (charter, Catholic, private).
This is very sad, both because it keeps happening, and because nobody is coming up with a better structure, it's not a topic of a wide discussion in the society.