What should I say to my project advisor who thinks I may not get a Ph.D position? I am an undergraduate student who is looking forward to work in Theoretical Physics in the future and therefore, I chose a project advisor who is a string theorist. But since, my grades are average and I failed his QFT course (which I am going to repeat anyway), he believes that I may not get a Ph.D position if I continue to do my undergraduate project with him. And he is trying to push me into fields in which I have no interest whatsoever. And he may be right.

I took his QFT course and I worked hard, despite that I failed, not because I am stupid, it is because I am a bit slow and he went with the course at blazing speeds (but I do not blame him, it is not his fault), but since, I took his course, I got motivated and deeply interested to continue with Theoretical Physics. In short, I am in this too deep to discontinue. And he keeps asking me this question,"What will I do if I do not get a Ph.D position in Theoretical Physics ?". And he wants an answer before he continues.

What should I answer him ?
Well, he has a point. You are not guaranteed to get a position (no one is), and you should have a backup plan.

Some possible solutions for a physicist are working as a software developer, a quant in finance, or teacher. You may also take a temporary job, hone your skills, and try again the next year. Another pre-emptive option, and what he probably has in mind, is to change to a field you are stronger in, and probably have a better chance of getting a position.

This said, if you really like this field, go for it and give it a shot. Just convince your potential supervisor that you are not delusional, you know the risks, and you are not overcomitting to a wild goose chase.