How/when to retract a project from a student?
With the way this question is framed, "retracting" the idea sounds both difficult and unethical. Based on the information given here, my advice, and the only ethical path, is for the supervisor to collaborate closely with the student on the work. If the idea is good, the pair should work toward a co-authored publication. This question states that, "since [the student] has more free time on their hands [they] could potentially have some results first." In this case, it sounds like collaboration with the student is very likely to help.

Working with students means teaching and mentorship. It means that supervisors are, "hassled by the student on learning the specifics" and it often means, "answering the students questions on the specifics of how to implement the said method [in ways that] take up more time/effort then just doing it themselves." This is part of the job of an academic supervisor.

Moreover, I completely fail to see why co-authorship and shared ownership of an idea between a supervisor and student is a problem. 

That said, one of the most important jobs a supervisor has is trying to decide when and what to delegate. It was the supervisors job to be more thoughtful and they need to deal with the consequences — whatever they are.