It works both ways. Just as how on a fixie bike, your legs can drive the pedals or the pedals can drive your legs.
If you wish to turn right hands-free, you must tilt both your body and the bike to the right. But first you must tilt your body, and due to good old Newton, that means applying force to the bike to the left. Due to trail, this will manifest as a subtle turn to the left.
One way of looking at it is that the angular force along the bike’s axis and the steering input are tied together. How is it that a bike leaning into a turn stays upright? Answer: centrifugal force counteracts the force of gravity on the bike and rider. How is it that the bike experiences centrifugal force? Answer: it’s traveling on a curved path. Why is the bike traveling on a curved path? Answer: the front wheel is steered in that direction.
So there’s a direct relationship between the two, but it’s not limited to already being in a turn. If you wish to make a right turn, you must first get the bike tilted in that direction. And if you’re currently upright, then you must apply a torque along the axis. Applying a torque to the right requires first steering left.
This can be done gently, even imperceptibly: a very tiny input starts the tilt, and after that you lag the amount you need to stay upright. For instance, say you steer left by 0.5°. The bike starts tilting over, and once it’s 10° over it requires a 5° steering input to counteract gravity. But you’ve only steered by 4.5°, and so the bike tilts farther. It hits 20°, which requires a 10° input, but you’re only applying 9.5°. And so on, until you reach the desired angle.
If you wish to turn quickly, this can be done all at once. You apply an aggressive countersteer until you are at the desired level, and then you apply steering appropriate for the turn. This is more difficult since the transition is harder, but the principle is the same. And it’s utterly necessary for anyone doing “serious” bicycling, like BMX.
All of this is symmetrical. If you ride hands-free, then you must first tilt in the appropriate direction to make a turn. And tilting in that direction requires first accelerating the bike in the opposite direction, which will naturally cause some countersteer. But it’s going to be a very subtle effect.
You might imagine that you could do it purely with weight shifting. If you simply locked the handlebars from turning left at all, you could get the bike tilted over without the countersteer. But you still applied a countersteer force; it just happened to be blocked. And most likely you fell on your ass before doing anything, because it would be impossible to ride such a bike in a straight line.
I have a rotary encoder on order. Hopefully it’s precise enough to show the effect. Might be a few weeks before I have the time to set it up, though.