Structural and electronic properties of NiMn2O4