Are you running QEMU directly, or through libvirt (GNOME Boxes, Virt Manager)?
EDIT: NVM I see you’ve answered that in another comment. I believe you can’t do this with QEMU directly. If you don’t need to be able to edit the VM config besides core count, disk size and RAM use GNOME Boxes. Otherwise use Virt Manager.