How can I find a PhD position to work on a highly specific idea of my own? I know exactly what I would like to research within my field, however, the ideas are too specific and indeed one of my feedbacks for the reject of one of my PhD applications based on my personal statement was that the university did not have the staff researching my interests.

My friend told me that being too specific, I limit my opportunities. On the other hand, being more general I would risk that I would have to research what the supervisors tell me to and therefore postpone solving the question I am interested in.

What are general strategies for finding appropriate places for studying PhD for someone who has a specific research problem one would like to solve? I am afraid that I may face a similar problem later when searching for a postdoc or an academic place in some research group.
You should look for faculty working in the field that you are interested in researching, and then pitch your research idea directly to them.

Make sure that you do a good job with a preliminary review of the literature for your idea and understand the professor's specific research interests, so that your letter does not sound like any of the hundreds of mail-merge messages that professors get every week.

If your idea is really worthwhile and you do a good targeted job of pitching it, changes are that someone will agree to work with you on it.  However, the reality is that most students come into a PhD without a really good sense of existing literature or the feasibility of their ideas.  It is for this reason that there is great value in being open-minded about your PhD thesis.

Many students make the mistake of thinking that the PhD should be the pinnacle of their career, solving some grand problem in human existence.  This might happen for a few figures in history, but, more typically, the PhD is the start of a research career and not the end of it.