magnetic moment of current carrying coil is a vector and its direction is given by right hand thumbrule, for rectangular loop, $\overrightarrow{B}$ at centre due to current in loop and $\overrightarrow{\mathrm{M}}$ are always parallel.
Hence, $(c)$ corresponds to stable equilibrium. 



