Apparently this is the most basic level of service offered by the Seamstresses' Guild. It is possible inflation has raised the price somewhat, but the popular title still remains.
While it refers to a kind of jam donut or jam-based dessert served with hot custard, like your mam might have made in your youth, it is also the slang name for an intimate service as might be provided by a seamstress, although this is not deeply explored. Or is it? Given the rather suggestive nature of the phrase it may well be slang for a donut and the proper name for whatever it is twopence will buy you up an alley.
Given what is known about relative prices in Ankh-Morpork, though, two pence does seem a little cheap for even a basic Seamstress service - especially as Guild tax on the transaction has to be paid (at 25%, or a halfpenny?) This is perhaps one of those terms lingering on from an earlier age, like "The king's shilling" for the bounty paid on joining the Watch, even if the current cost is a lot different? (Down-to-earth American slang has the expression spreads faster than a two-dollar whore on a Saturday night; again, an older price prevails in the folklore? It'd be hard to find a Seamstress in today's USA who'd charge a dollar a sock...)
Either way, we are introduced to the expression in Night Watch during the events leading up to the Glorious Revolution perhaps to be offered as a bribe by a fledgling Rosemary Palm seeking to escape the clutches of Cable Street Particulars.
A 2p (not 2d) Ankh-Morpork Post Office stamp honors the Seamstresses' Guild.