@Muhammad Zeeshan,Thanks for posting in Q&A.
From your description, I know you want to know why the uninstall remediation script did not work.
Based on my research, if you want to uninstall an app, you should first stop it and its services, then you can uninstall it manually or using script. However, please be sure the command can uninstall the app properly on the device, and the detection script is correct then you can deploy it via Intune.
Moreover, you can monitor your script packages and remediation status for a device.
https://learn.microsoft.com/en-us/mem/intune/fundamentals/remediations#monitor-your-script-packages
If there is any unclear, feel free to let me know.
If the answer is helpful, 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.