Technically, the distinction isn’t in the material but the function: dam - water on both sides, levees & dikes - water on one side of it.
There’s a lot of geographical variation in how those terms are used, too, which adds to confusion 🙃
But a beaver dam is not made of concrete and still a dam 🌊🦫🪵🌊