If you want to challenge or express doubt about the questioner's right to know why you did or do something, you might use the U.S. idiom "What's it to you?" For reasons unclear to me, Christine Ammer, American Heritage Dictionary of Idioms, second edition (2013) addresses this expression within a listing for "what of it?":
what of it? Also, what's it to you? What does it matter? Also, how does it concern or interest you? For example, I know I don't need another coat, but hat of it? —I like this one, or What's it to you how many hours I sleep at night? The first term , a synonym of SO WHAT, dates from the late 1500s; the second, another way of saying "mind your own business," dates from the early 1900s.
These are essentially two separate expressions, and in my opinion Ammer should have treated them as such. If she had done so, the entry for "what's it to you?" would have read like this:
what's it to you? How does it concern or interest you? For example, What's it to you how many hours I sleep at night? This term, another way of saying "mind your own business," dates from the early 1900s.
Even then, I would demur a bit from Ammer's assessment of what the expression means. It is certainly a challenge to the original questioner to establish that the questioner has a sufficient objective interest in the subject of the question to justify asking it. But because it is framed as a non-rhetorical question, it seems to me to be significantly more polite and far less dismissive than saying "Mind your own business," or "None of your business," or "Ask me no questions and I'll tell you no lies," or (as an example of a more aggressive and more purely rhetorical question) "Why are you poking your nose into places where it doesn't belong?"
I don't deny that "What's it to you?" has a bit of an edge to it. It falls somewhere between the sort of thing Miss Manners would say to deflect a Nosey Parker (such as "May I ask why you have an interest in this particular subject?") and something a tough guy might say to Sam Spade in a detective novel (such as "Who wants to know?") But it admits the possibility that the original questioner will supply a rationale that the imposed-upon person will find compelling. And this quality preserves it from being as rude as some of the alternatives I've mentioned.