He did not say this on his own, but since he was high priest for that year, he prophesied that Jesus was going to die for the nation,