Here is how I rooted my Motorola Edge 40 (can be applied on other Motorlola phones). Sharing because I had hard time finding good rooting guide. Hope you find this usefull.
Do at your own risk and only if you know what are you doing.
NOTE: i got fastboot working after couple of tries, here is the process i expect to work