The FBI had a warrant to retrieve all documents that Trump had absconded with, so it would have been absolutely necessary to open any and all safes on the property. It is not illegal to own a safe. What was illegal was Trump taking documents that he had no legal authority to take.