the astronaut is rotating the pole on which the flag is mounted, trying to get it to stay up. The flag is mounted on one side on the pole, and along the top by another pole that sticks out to the side. In a vacuum or not, when you whip around the vertical pole, the flag will ``wave'', since it is attached at the top. The top will move first, then the cloth will follow along in a wave that moves down. This isn't air that is moving the flag, it's the cloth itself.
: Many HBs show a picture of an astronaut standing to one side of the flag, which still has a ripple in it (for example,
see this famous image). The astronaut is not touching the flag, so how can it wave? The answer is, it
isn't waving. It looks like that because of the way the flag was deployed. The flag hangs from a horizontal rod which telescopes out from the vertical one. In Apollo 11, they couldn't get the rod to extend completely, so the flag didn't get stretched fully. It has a ripple in it, like a curtain that is not fully closed. In later flights, the astronauts didn't fully deploy it
on purpose because they liked the way it looked. In other words, the flag looks like it is waving because the astronauts wanted it to look that way
No, it wouldn't be stiff. You could still wave it around, because it has mass and therefore inertia. It won't look quite normal, though, because there is no air to fill it like a sail.