The magnetorotational instability (MRI) is considered to be a promising mechanism to amplify the magnetic field in fast-rotating protoneutron stars. Many local studies have proven that the magnetic field could be amplified on small scales. But to explain the dipolar magnetic field strength of the magnetars (10¹⁴-10¹⁵ G), a large scale magnetic field needs to be generated by the MRI. To study this question, a three dimensional pseudo-spectral code has been used to develop a global model of the MRI in a proto-neutron star. The hypothesis of an incompressible fluid allow us to simplify at maximum the model. We compare the turbulence in the global model and in local simulations. We also show that a strength of the dipolar magnetic field consistent with the values of magnetar’s strong fields can be generated by the MRI, even though it is lower than the small scale magnetic field. Overall, the results presented in this talk support the ability of the MRI to form magnetar-like large scale magnetic fields.