Hey Sarthak!
My name is Ravi, an independent advisor and expert user. I am happy to help you. :)
I understand how concerning it can be when a PC doesn't load properly.
I see it's an old computer. I hope you checked the minimum requirements before upgrading to Windows 11. If a PC doesn't meet Windows 11 requirements, it doesn't work properly.
For now, try using the recovery environment to repair Windows.
1). Turn off your PC
2). Start the PC, when Windows starts loading, press and hold the Power Button for 5 - 10 seconds to perform a Hard Shut Down
3). Do it twice.
4). When you start Windows the third time, it will boot into the Recovery Environment. You can access Startup Repair, Command Prompt, and other options.
5). Go to Troubleshoot - Advanced Option - Startup Repair and check if Windows can repair itself.
Feel free to get in touch again if you have any additional questions.
Cheers,
Ravi