The first step is to fill the sinks in the DEM. Sinks are artificial depressions that trap the water and prevent flow to the outlet.
1. Start QGIS Desktop with GRASS.
2. Add dem.tif to the Layers panel.
3. Open the Processing Toolbox panel: in the main menu go to Processing | Toolbox.
4. In the Processing Toolbox choose to GRASS | Raster (r.*) | r.fill.dir.
5. In the r.fill.dir dialogue choose the DEM layer as Elevation. Keep the default Output aspect direction format as grass. Save the Depressionless DEM as DEM_filled.tif (make sure to choose a GeoTiff) and uncheck the other output layers, because we don't need them.
6. Click Run. Close the dialogue after processing. Processing will take a while. Ignore the red warnings in the log.
More info about the algorithm can be found here.
7. Remove the DEM layer from the Layers panel so we only have the DEM_filled layer there to proceed with.