It’s like a transit card: you have $10 on the card, one ride costs $2 — enough for 5 rides. Same here. The risk is $10. The stop is 2% below the entry: every $100 of the trade loses $2 when the stop triggers. To lose no more than $10, you take 5 times $100 — a $500 trade.
If the stop is 5% from the entry, every $100 loses $5, and the trade will be $200. Stop further away — smaller trade; stop closer — bigger trade. The risk stays the same every time: $10.