This is possible, but only via the command line tool grbtune
https://docs.gurobi.com/projects/optimizer/en/current/features/tuning.html#command-line-tuning