I came up with this for someone who had similar requirements to yourself, but this adds a new attribute into every node rather than an element. It could be adapted to add an element instead. If nothing else, it may give you some further ideas on how you could achieve your requirements.

I did review that thread before posting here. It is what inspired the line in my OP, "In practice my XML is much more complicated so I could not reasonably shred and flatten to do the change and the reconstruct via SQL."