Is it appropriate for a PhD student to write reference for a PhD applicant?
I think this is in part a cultural question. For example, in the US, I think letters from current graduate students are not given nearly as much weight as from more "senior" professionals. However, in German schools, it is quite common for senior doctoral students to write letters of recommendation for undergraduates, particularly in disciplines such as engineering, where the group sizes tend to be quite large, and in many cases the professor in charge of the group may never meet the undergraduate in question.