The X-Men were created for two primary reasons. One was because Stan Lee needed another superhero team and was feeling kind of lazy, so he threw up his hands and said, “You know what? They were just born that way!” The other was as a at-times heavy-handed anti-racism allegory. The year was 1963, and the Civil Rights Movement was heating things up across the country. Younger readers of comic books could be taught a lesson on tolerance, and comics were a good medium for that, so here were the X-Men, mutants who were feared and hated by non-mutants for the crime of being born different. But the X-Men were good and defended regular folks against the evil mutants of the world, in an attempt to prove that not all mutants were evil.
Even given the sliding scale of Marvel time, where everything outside Captain America and the Invaders’ exploits during World War II depicted in a Marvel Comic (barring the upcoming Secret Wars) has taken place over a roughly 12 year time period, the X-Men really suck at their task of promoting tolerance.