I believe he had been luring powerful men to his island, filming them with the underage girls he'd provided them with and then he blackmailed the men.
Some say he was smuggled out the back door and a dead homeless man was put in the body bag. Most agree he was murdered.
Epstein was very arrogant and would have believed he'd beat the rap again. He expected his 'friends' to come to his rescue again. I don't think he would have killed himself before the trial. Not before. He would have sung like a canary first.