Quantum description of twisted electromagnetic wave propagation