It was common in the Middle Ages that lots of things in the Torah are allegorical. Maybe they did not use that for the flood, but it was used. You have to say it in lots of cases. King David wrote in Psalms, "I am a worm, and not a man." That surely has to be an allegory (I think).