Hello Guillaumeb89,
As a possible workaround, if you already have DEM: build mesh model using DEM as a source surface, crop it by the shape that you need to use as a mask (set as boundary, then duplicate model with "clip by boundary shapes" option enabled), then run Generate Masks process using "From Model" option.
Probably, before clipping the model by shape you can also smooth it using high Strength value (like 50 or even 100) to make the surface almost flat, if it is related to the water only.