
The theory of relativity demands that both time and space are elastic. Which means that space can stretch, too. The elasticity of space can be distorted by stretching and shrinking. Space can also be curved.
As is commonally aware, the angles of a triangle add up to 180 degrees. However, if you could put a flat triangle across the face of the Sun, the angles would add up to slightly more than 180 degrees, because, in accordance to the theory of relativity (see "Relativity" topic page) the Sun's gravity curves the space around it.
This curvature is only slight. We need a much bigger gravitational field, like that of an entire galaxy containing hundreds of billions of stars. By our line of sight, if a galaxy lines up exactly in front of another, then the intervening galaxy's gravitational field acts like a type of lens, which bends the light from the more distant galaxy and focusing it, producing a kind of "halo" effect known as an "Einstein Ring".
Very large spacewarps like this can also occur near a black hole where space is incredibly warped.
In 1935, Einstein and Nathan Rosen theorised the "Einstein-Rosen Bridge" (see image at the top of this page). The Einstein-Rosen Bridge, or, "Wormhole", is similar to a black hole, where it curves space but, instead of plunging down and do for ever, it opens out again to form a second surface underneath.
Passing through a wormhole, you could emerge in some other point of the universe or, in a different time! (See "Time Travel" topic page.)
Wormhole theory totally complies with the laws of relativity. Although as yet, none have been discovered.