Rainbows are caused by bending of sunlight as it hits raindrops falling from the sky.
The light is bent (refracted) and split into a rainbow of colors.
This is because each color of light gets bent by a slightly different amount.
A rainbow is always directly opposite the sun from the observer. This explains why rainbows are only seen when the sun is low in the sky, usually in the late afternoon.
The rainbow's location will appear different for observers at different locations, but it is always directly opposite the sun.