What have you tried so far?
The documentation on loops can be found in the "'Add a Loop Start'" subsection of the "‘Other Stuff’ Screens" section of VoiceAttackHelp.pdf (press F1 while VoiceAttack has focus to open it in your default PDF viewer).
However, this can be done without using loop actions, as you can use the "Repeating" option of a command combined with a keypress action (with its "Hold down for seconds." option set to the amount of time you want the key to be pressed), and a pause action.
To stop the command from another command, you can use the "Stop Another Command" action, which, as the name implies, does exactly that.
You'll also want to have another keypress action in the command that stops the other command that releases the key, in case it's down when the command is stopped (very few applications respond to releasing a key that was already released, so that's generally not an issue).