How to create 3D printing file (e.g. STL, OBJ and IGES etc.) from DEM?
This question has been answered on a sister site, GIS Stack Exchange. It's a rather comprehensive answer posted, which means it's impractical to summarize here.

GIS answer

The answer does indicate that a plug-in for QGIS software is needed in order to accomplish this objective. If you do not use/have the QGIS software, my answer is invalid.  All three answers to the question linked above appear to point to the same program/plugin.