Formation and stability of rocksalt ZnO nanocrystals in MgO