Can light be rotated using lenses or prisms? I was wondering if it was possible, by using only lenses, mirrors, or prisms, to rotate a ray of light coming from a certain direction. For example, if I have two lasers beams side by side, is it possible that after going through an optical setup, that the laser beams appear one on top of each other? I don't want to use stuff like optical fibers or electronics, I just wish to know if it is possible to do it with purely optical devices.
 A: Yes, it's necessary for example on some telescopes to keep the image the same way up on a camera as the telescope tracks across the sky. VLT naysmyth focus
There are a couple of optical designs, using either rotating prisms or a rotating set of mirrors. Look up field rotator. eg http://www.ing.iac.es/~eng/optics/documents/OPT-WHT-001.pdf
A: There are four types of prisms: dispersive (like the one Newton was using), reflective, rotative, and displacive.Dispersive prisms, usually in the shape of a triangular prism, are used to separate the different wavelengths of an incident beam of light into different optical paths. Reflective prisms can be used in imaging systems.  Due to the total internal reflection, light entering the prism can undergo multiple reflections until they reach an output face.  Anamorphic ones are usually configured in pairs to keep the beam traveling along the optical axis.  More in depth about optical prisms here
https://www.opticsforhire.com/blog/optical-prism-design-types
John and Viktor
A: Yes you can. Moreover, you don't need any lenses and such things, you only need a medium with Refractive index $n(\vec r)$. Using Fermat's principle (https://en.wikipedia.org/wiki/Fermat%27s_principle) you can calculate the path of the light travelling through a medium with $n(\vec r)$.
You just have to choose a proper $n(\vec r)$ function.
