Rooting means gaining full acess on your phone and you do that for a specific reason and most of the reason is installing custom rom and if there is no custom rom then there is no profit.
And magisk is an app by which you can root your phone and install modules like viper4android which increases sound quality and other modules like that .
I would recommend not to root the phone. You can root after there is a custom recovery or rom
as of now there is no available custom rom for oppo A12.
I did'nt tried because there is no profit of doing that as there is no custom rom or custom recovery for it you can only install magisk modules and voiding your warranty .