We were all safe because we evacuated to the school.
To ensure our safety, we took shelter at the community hall.
hannaさんの英文でも大丈夫ですよ。他にも次のように言えます。
ーWe were all safe because we evacuated to the school.
「学校に避難したのでみんな安全だった」
ーTo ensure our safety, we took shelter at the community hall.
「安全を確保するために公民館で避難した」
to take shelter で「避難する」
ご参考まで!