It's not that difficult, actually. A demand needs to be made, but halt or stop is not considered one.
So, you must ask something for the guy, or state a RP reason why they should stop. like police: "This is the law. Please stop for inspection." That is a proper demand. Stop to be inspected. Not just stop.
Players that get sanctioned for not making a demand after warning a vessel multiple times is because repeating stop multiple times is not a demand.
"Stop!" "Cut your engines now!" "Hey, I said stop!" - no demand there.
"Stop, now gringo! These are the Corsairs! Are you carrying any food, amigo?" - you made a demand there, besides telling the guy to stop. You made clear you are interested in something.