Ferromagnetism and diamagnetism behaviors of MgO synthesized via thermal decomposition method