Hi @Abdullah ,
Microsoft 365 E5 for enterprise customers includes Microsoft Entra ID P2 as part of the bundle, so once you assign the E5 license, the Entra version should upgrade.
https://www.microsoft.com/en-us/security/business/microsoft-entra-pricing
If the information helped you, please Accept the answer. This will help us and improve searchability for others in the community who may be researching similar questions. Otherwise let us know if you have further questions.