Every writer is asked this, at least from time to time. Postgraduate researchers are asked this too, particularly in the viva.
“Where do you get your ideas?”
“Why did you want to follow this research topic?”
“How did you know to do this?”
In your viva you have to be willing to talk about what started your process, how you knew to do something, why you wanted to do it and so on.
Ideas could come from reading. They could come from your supervisor. There might be a highly personal story or a really mundane, practical reality to them. It may be that on the way to working on one project you spotted something interesting that you needed to explore. There are so many routes to inspiration.
You need to be able to talk about the origin of your ideas in the viva, but don’t forget that as interesting as those ideas are they are nothing without the work that has developed them. Your work might be inspired by 100 papers, a chance encounter or by a funding advertisement – but it’s your work that has created your success, not the idea itself.
Wherever your ideas came from, it’s your work that has taken you so far.