idk if thats a wise idea jailbreaking has a pros and cons but anyway you can root with two methods the first one is by using a computer and the second is by using a supicious app such as kingoSU which is available for free on there website.
first you have to unlock the boot loader then the phone goes into reset first you have to unlock the developer option before doing it then after unlocking everything you download the TWRP and Magisk and the root is done but follow a more detailed guide I recommend there is also Youtube I just gave you a tip