In most countries that are ethnically diverse, that diversity was created through various forms of colonialism. Often with racial imperialism deeply ingrained in it. Which means those countries have long running strains of racist ideas and ideologies that forms the foundations of the ethnic "in group" and "out group".
Which is not to say that ethnic strife doesn't exist in non-colonial countries as well, but that this line of thinking and examination is a) extremely complex, b) inextricable from the history of the systems under examination, c) inextricable from deep histories of racist thought - often imposed by colonnial or imperialist powers, and d) similar to social darwinism in that it is often presented as common sense, but leads to some very dark places when taken, unexamined, to its logical conclusion.