Your boyfriend is confused. He's confused about the relationship. Again your relationship, as he sees it, is affecting his studies. Thus, he feels he'll fail in his exams if he continues it for the time being. After he completes the exam, he will come back.
You don't have to end a relationship because of an upcoming exam. He should have asked in a kind way if you shouldn't chat frequently for some time or take the relationship slowly so that he can study for his exams. Or, you might have worked out on what to do so that the relationship doesn't affect his sitting for the exams.
He was confused. If someone is confused about a relationship, it's better not to continue in the relationship. It simply means he doesn't know whether he should be in it or out. Who knows? After the exam, you might not hear from you.
Since you are partners, he should have asked for your advice. Then, the two of you would have come up with how to go about the exams and his confusion about the relationship.
You should accept his decision. You should move on with your life. Let him know you won't object to it because that's what he wants and you can't force him. But, it hurts that he can end the relationship because of exams and that he's confused about the relationship. You will move on and if you were meant to be together, it will be known by then. Wish him all the best in his exams.
It's time you move on.