Prejudice may be formed when an individual belonging to their group develop an authoritative personality. The person then feels superior and sees the characteristics of their group as the right ones and the only way the things should be done. What is different from this is wrong and bad and needs to be punished.
Prejudices do not always lead to open conflict or discrimination. Sometimes people simply internalize negative attitudes based on prejudice and avoid the group members or feel uncomfortable next to them. This creates a mental burden for the prejudiced person, hence having these mental errors (how they are referred to in social psychology) is bad. This could be one way to encourage a prejudiced person to work on their belief since they wouldn’t be motivated to improve the wellbeing of others but could get motivated by a personal benefit.