Sure you would. Especially for the kinds that don't come in bars.
I'm going to buy people fancy soaps for Christmas this year
Don't drop the soap!
Both ways of referring to soap as an actual object instead of a substance. I mean beer generally comes in glasses but you don't go around saying 'a glass of beer please'. I mean you can but sometimes it feels pretty redundant and strange. So yeah, you can go to a shop that sells bars of soap and buy 'a soap' without having to point out they sell them in bars, y'know?
Sorry, but I disagree. HarriOxo asserts that a native speaker of English would not say "a soap." Your examples are "fancy soaps" and "the soap." Those are things we might actually say, but they don't support the argument that we would commonly say "a soap," which we wouldn't.
The only situation I can think of is if somebody were choosing "a soap." For example: "I'm looking for a soap that won't dry my face." In the context of this particular lesson and sentence, which is what we're discussing, one would never say, "Hand me a soap" or "A soap, please."
They're both examples of 'soap' being used as an object, instead of a mass noun, so of course you can use the indefinite article with an object, and you don't need to say 'a bar of substance' to refer to countable soap objects
If you go into your shop that sells fancy soaps, you could say "a soap please" and the assistant could say "hand me a soap" to someone who's stocking the shelves behind them. There's nothing remotely strange about this at all, but agreeing that we might say 'soaps' or 'the soap' but somehow not 'a soap' is a pretty weird stance. Especially when you wouldn't say the same applies to other objects-from-mass-nouns, like 'a beer' - there's no grammatical rule being applied here, so it sounds like you're just generalising about usage?
Really the only reason I wanted to clarify this is that yet again there's someone in the comments proclaiming that "no native speaker would ever say this!" I'm a native speaker, it's completely normal to refer to bars of soap (or tubs of shaving soap, etc.) as just 'a soap' - maybe you've never heard it, but that's just your personal experience of a language spoken by hundreds of millions of people around the world
Why do you think the sentence here is being used in a shop?
Suppose you are at a summer camp. As a courtesy to the campers, the camp staff keeps toilet articles, such as soap, toothpase, and combs, behind a counter, and between 4:00 pm and 5:00 pm, a camp supervisor stands behind the counter ans hands out supplies.
"Do you want toothpaste?" he asks you. "No," you say. "A bar of soap please".
Or suppose you are in a drug and cosmetic shop. The bigger articles are out on the main floor. But to prevent shoplifting, the smaller articles are kept behind a counter. So, not seeing soap on the main floor, you go up to the counter and say ... .