If you know the profile removal password, you can directly delete the MDM profile. To unenroll an iPhone from Company Portal, you can do the following:
- Tap Settings > VPN & Device Management.
- Tap Remove Management and enter the removal password.
Or if you don't know the removal password, you can choose to reset the device to factory settings. But this will erase all the data and content. And you cannot choose to restore from iCloud or iTunes. The MDM profile will come back once you choose to restore your device from a backup. Without losing any data on your device, you can use a professional MDM removal.