Edit: here is a writeup I put together for someone else. I had major and minor issues the whole way towards upgrading the first ROM on 12 that was also based on OOS12. Pretty much a cliff notes of a few things ethereal has been helping everyone around here with, lately.
I'd review that process and apply it to your needs.magisk would come along as another boot.img flashing at the very end, after you enabled adb and got the custom img created from magisk ( or someone on stag can provide you with a patched img, but I highly suggest you do it yourself. Its too easy with fastboot enhance to not)
Original reply: side loading magisk is not the supported method per Dev anymore. It works, for the most part and I honestly dont know exactly the main hold up against it, but its better to extract the boot.img from the zips payload.bin via python script or fastboot enhance.
Extract the img, put it on your device and select it with magisk. The patched version magisk makes will be in Downloads. Copy it to your PC, reboot to fastboot and run "fastboot flash boot boot.img.
You should probably flash the 2 other required images from the ROM zip, btfo and vendor_boot, as well.