The colour white is in fact a mixture of all other colours, and normal daylight or sunlight is a mixture of all the other colours of light in the same way. Light can be split up into the many different colours of which it is made by passing it through a prism.
The refractive index of glass varies with the wavelength, hence the colour, of light, so each colour emerges in a slightly different direction to the others.
The splitting of white light into it's constituent colours is called dispersion.
Notice that red light is refracted the least and violet the most.
It is possible to combine colours to produce white light. For example, cyan and red produce white. This is illustrated in the diagram.
Notice the colours in the above diagram are mixed. The same effect is not obtained by overlapping filters, which block all light except for the colour of the filter. If filters were used here, the central region would be black.