Jenkins -> Execute commands in Dockercontainer on a remote vm

I have a Jenkins server with virtual machines registered as agents.

On each of the machines there is a DOcker installation.
Now I would like to execute commands from Jenkins within the pipeline in the Dock containers that were created on the individual agents.

Swarm is out of the question for me for certain reasons. How else could this be solved? I would probably have to specify the VM as the parent agent in the pipeline and then the individual containers.

Best regards