Hello,
If you want to stop a vm that is in HA. You have to use the shutdown button in the Proxmox interface, that will change the HA state of your vm to "stopped".
If you shutdown your vm directly in the VM, HA don't see it so your VM will be automatically restarted.