Cold atom setups are now commonly employed in simulations of condensed matter phenomena. We present an approach to induce strong magnetic interactions between atoms on a self-organized lattice using diffraction of light. Diffractive propagation of structured light fields leads to an exchange between phase and amplitude modulated planes which can be used to couple atomic degrees of freedom via optical pumping nonlinearities. In the experiment a cold cloud of Rb atoms placed near a retro-reflecting mirror is driven by a detuned pump laser. We demonstrate spontaneous magnetic ordering in the Zeeman sublevels of the atomic ground state: anti-ferromagnetic structures on a square lattice and ferrimagnetic structures on a hexagonal lattice in zero and a weak longitudinal magnetic field, respectively. The ordered state is destroyed by a transverse magnetic field via coherent dynamics. A connection to the transverse (quantum) Ising model is drawn.