Basically an object that does not allows any light to pass through will form ashadow. Shadows are formed by light, because if light shines onto an object, and the object blocks the light, the light will go sideways of the object, and therefore, ashadow is formed. Light can only travel in straight lines.
The change in direction of a wave, such as a light or sound wave, away from a boundary the wave encounters. Reflected waves remain in their original medium rather than entering the medium they encounter.