Galaxy alignments: Theory, modelling and simulations