People Ask Why Some Root Their Device and For Me This is Why
I am a Tasker enthusiast and when I can automate something simple on my phone I like to. I set a simple task to turn off WiFi when my home network is not detected so my phone doesn't scan and report my location to businesses. However, this functionality is now nonexistent and the developer has to ask people not to one-star their app because it doesn't work. My phone is my phone and killing my ability to use it as such for whatever security theater Google is playing at is why I root my device. Anyone else still rooting for similar reasons?
Rooting a device is a process that depends on the phone and manufacturer. On some devices it is flat out impossible, on other it is trivial (those tend to be increasingly rare). The steps usually go something like this
Put your phone in developer mode
Unlock the bootloader (that's the part that is manufacturer/phone dependent)
Use fastboot to install a replacement bootloader (I used TWRP in the past, now I use Orangefox)
Once you have a good bootloader, youll be able to install apps from outside Android. This will enable you to give those specific app root access.
Install Magisk or superSu or whatever app that gives you root access once booted back in android.
Keep in mind that you can 100% brick your phone doing this and that it'll most likely void your warranty. Do not root your device following this post alone. I tried to answer an ELI5, not a Teach Me How To Do It Like I'm 5.
More information:
bootloader : that's like the BIOS of your phone. It's software that is used right before your OS (android) launches
fastboot : that's a mode you can set your phone in that will enable you to run commands via a computer to which your phone is plugged by usb. You can upload custom code to it this way (such as a replacement bootloader)
Steps 2-3 are sadly impossible on most devices. If you have one of the bad ones, I'd recommend making some searches before you choose your next device.