What separates white lights into bands of color lights?

Light travels more slowly through 'optically dense' materials such as glass and diamond. The different wavelengths of light also move at different speeds in such materials, the blue light moves more slowly than the red light part of the spectrum, so all of the different colours that make up white light can be separated out when the white light enters the material at an angle. The blue light will bend more than the faster red light.