Hey thx for the question. In the Bible, God hates death. “God didn’t make death. God takes no delight in the ruin of anything that lives.” (Wisdom of Solomon 1:13) Even the death of the wicked is sad (Ezekiel 33:11). Any act of taking a life has an involved spiritual logic and is deemed absolutely necessary.
The Flood is the sequel to the Genesis 6 event. After the angels infect humanity with their own genome, even animals and plants seem to be compromised, and the human may be going extinct. The primary purpose of the Flood seems to be a spiritual cleansing of a malign spirit energy, but also an effort to eliminate the alien intrusion.
The grammar appears to suggest it’s a local flood (see here etc. etc.) and perhaps centers on a core area- perhaps modern Israel, which is also probably the Eden location, a landscape whose ‘spiritual ownership’ is highly contested to this day. As in the mikveh and baptism, water appears to restore a body to God’s ownership, or a neutral spiritual ownership.
I would just warn that the Bible is the mystic literature of a long-dead people who left little or no clues to its interpretation. It must be read carefully, with an awareness that important subtexts and even characters in the drama can be disclosed indirectly.