What is Snell´s Law?

How does refractive indices change the angle at witch light moves through a medium.

The speed of light changes depending on the media the light is traveling through.
Thus, placing two different media next to each other forms a boundary layer where the two materials touch. 

The light bends at this junction when it travels through the two materials in accordance with Snell´s Law named after Willebrord Snellius, stating the following:

n1 sin θ1 = n2 sin θ2

where n1 and n2 are the refractive indices of the two media,  θ1 and θ2 are the angle of incidence.

This optical phenomenon is broadly used across most applications within optical instrumentation as it is one of the fundamental principles of light and material interaction.

An example from everyday life is for instance when a straw is placed in a glass of water and it appears to bend at the water-air interface.