Suppose a kafir child at age of 15 or 16 heard and studied Islam, but did not enter and they were a stubborn disbeliever. Will they be punished if they die at age of 17? Will they enter Heaven?
According to Islam, only That person will enter Heaven, who will say Shahada even before last breath , Otherwise not. and in Islam, the Age at which a person's accounting starts, it is the day when they reach puberty. Since that time of puberty, their accounting is started.
So at age of 17, all boys reach puberty, and as he did not said his Shahada before his death, he cannot enter heaven.
Here is fatwa related to it: https://islamqa.info/en/197392
And Allah knows the best