To separate people by race or religion is to segregate them. In general, the word segregate means to separate one type of thing from another.
In the United States, the practice of segregating blacks from whites in public schools and public places was common in the South until the 1960s. Because of this, people don't even like to use the word segregate in its neutral sense. But you could rightly say that new bicycle lanes are designed to segregate bikes from auto traffic.