O-methyltransferase that catalyzes the 2 O-methylation steps in the ubiquinone biosynthetic pathway. 3,4-dihydroxy-5-all-trans-polyprenylbenzoate + S-adenosyl-L-methionine = 3-methoxy,4-hydroxy-5-all-trans-polyprenylbenzoate + H(+) + S-adenosyl-L-homocysteine a 3-demethylubiquinol + S-adenosyl-L-methionine = a ubiquinol + H(+) + S-adenosyl-L-homocysteine Cofactor biosynthesis; ubiquinone biosynthesis. Component of a multi-subunit COQ enzyme complex, composed of at least COQ3, COQ4, COQ5, COQ6, COQ7 and COQ9. Belongs to the class I-like SAM-binding methyltransferase superfamily. UbiG/COQ3 family.