@Ritesh Sharma Thanks for posting in our Q&A.
For troubleshooting windows devices enrollment, we usually go to Settings > Accounts > Access work or school > click on your work or school accoount > Info > Create report > Export. We will see the report under the path it provides.
Or we usually check the logs under Applications and Services Logs/Microsoft/Windows/DeviceManagement-Enterprise-Diagnostics-Provider/Admin in Event Viewer.
https://learn.microsoft.com/en-us/windows/client-management/mdm/diagnose-mdm-failures-in-windows-10#collect-logs-directly-from-windows10-pcs
Hope it will help.
If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.