Gravitational lensing is one of the predictions of General Relativity. It predicts that massive objects can act as lenses to shift the position of distant objects or produce multiple images.
In Einstein's General Theory of Relativity the path taken by light from a source to an observer is along a geodesic in a four dimensional spacetime. In this theory, gravitational forces act as distortions to the surface. The theory predicts that the path of light is bent by gravitational forces – confirmed in 1919 by Eddington's measurements of the positions of stars during a solar eclipse.
The departure from a straight line depends on the mass of the body between source and observer. If the mass is big enough then multiple images of the source may be seen.
The lensing object can be any massive object eg a black hole or galaxy. The images of the source are usually distorted by the lensing object, and is confirmed by other means – such as spectrographic analysis - to be images of the same object.