I am new in this field and I am having a problem with my DEM, (SRTM 30M).
When I calculate flow accumulation a straight line appears if I fill the DEM. And rivers are not connected if I don't fill it.
How can I solve this problem?
The issue looks like its due to the nature of the fill algorithm (as others have mentioned), which can create large flat areas with parallel flow lines. Your other option, although its a little more difficult in ArcGIS, is to use a breaching algorithm. Open source GIS software like WhiteboxGAT has tools available to do this.
If you have a previously delineated stream network, you could rasterize and burn this network into your DEM to force flow to that network. You could also burn a flowline into your flat area are then rerun the fill algorithm so that the flow in that area is forced into the drawn flowline.
The line that shows up is probably a normal thing to happen. If it is a flat area all cells from a large area flow into 1 line. This line will get a very high number and will appear as a straight line.