Fewer people died inside the prisons than in 2023, when prisoners were five times as likely to die as the national average.