White light is made up of a spectrum of seven colors,
Red, orange, yellow, green, blue, indigo and violet.
When travelling from the air to the glass prism, light rays of different colors slow down to a different extent, so the light rays will bend by different angles.