I actually tried this. The problem is that your average fortress and your average D&D dungeon, in fact, serve very different needs
1: Ease of access. Once you get into the meat of most fortresses, so to speak, they're intended to be easy to navigate/pathfind, with all the important areas off major traffic areas. though failed projects and such can get a little nuts, fortresses ultimately strive to be logical places. Not so with dungeons: the meta-point of your average D&D dungeon is to conceal something: Treasure, the boss, et cetera. The reason why the PCs are in the dungeon is going into be the farthest, hardest to access, middle-of-nowhere sort of place, except it's probably also going to be impressive.
2: Linearity. Fortresses are often not linear: they branch off in every direction to try to keep the steps-from-center minimal. A dungeon, by comparison, is very linear: there may be a few branches to go off in, but ultimately there is an idea of "forward" to progress. This might be de-emphasized in your average D&D game as opposed to most CRPGs (where there is one path, and some side rooms if you're lucky), but filling out a non-linear space is extra needless work for the DMs if the players don't encounter it, and frustration for the players in not being able to discern "forward"
3: Size. Fortresses are big. I mean, really big, compared to a D&D dungeon. If I design a dungeon for mid-level PCs, it will generally have 3-5 important rooms/zones (the places with fixed, relevant encounters) and twice as many unimportant ones along the way or off it. It's all essentially on one z level. A truly massive dungeon, the big multi-session show-stoppers I can pull out once a campaign or so, might feature between seven and ten z, each probably somewhat smaller than the "average" dungeon. The largest dungeon I've successfully run had about thirty rooms -- it's not the largest I've designed, but I haven't had a chance to pull out anything more titanic. A fortress? Well, let's look at a good early fort.
At the start of my latest fortress's second year, It extends across 7 z-levels. Two of those are decently minor: the "surface" and "entrance" levels would have 2-3 good encounter sites per. The next level down features a massive mechanics area that, in D&D terms, would consist of another 4-5 rooms, as well as the underground tree farm. The level with the actual farms, ten rooms but they're all uninteresting by default. the stockpile level below that is small again, and then we get to the meat of the fortress: the "living" floor has fifteen rooms in three directions, and the work level below that has another dozen. This would be decently insurmountable, except that everything below mechanics/tree farm is within 20 steps of the main stairway (and almost every room can be accessed in under a dozen steps from the stairs). I might be able to tool this fort into a dungeon, but this is a minimal fort that's only had a year to build. A "real" fort, one that's 5-10 years old and supports 100+ dwarves, is orders of magnitude more complex and big
What I've found I CAN do is apply principles of fortress design to dungeon design, especially when it comes to supply chains. Dwarf Fortress tells you what a self-sufficient enemy lair needs, but you have to think D&D to put it together in a manner that's enjoyable to run for both players and DM. The stockpiles move to the bottom, behind your arena/royal throne room/boss chamber. Food production is all put off in a wing, probably with the jail next to the butcher's shop to keep things "interesting". Living quarters are all rendered barracks to reduce the number of "rooms" the players have to worry about, and they're probably put 'behind' prime encounter sites (like the meeting hall with artificial waterfalls) so that PCs/invaders will enter from one end and 'locals' from the other. The central staircase/borehole is done away with in favor of having a few defensive emplacements on every z level that need to be gotten through to reach the next ramp/stair down (this is done to preserve the DM's sanity as well as player fun. The players don't just want to walk to the bottom, hit the objective and leave. The DM doesn't want to design a massive dungeon and have it not even remotely explored). the number of workshops is probably minimized: gone is the masonry, carpenter's workshop, and dozen craftsdwarfs workshops, while a single room holds the entire magma metal industry (with plenty of magmatic death pits to fall in bull-rush enemies into). Fortress workings like the underground tree farm, pump-stack, and water reactor are either MIA or (in the case of the mechanics) sealed off while their effects (magma cistern, mist generator) are visible features.
I could build this in DF, and it would probably run as a fortress, but it wouldn't be very effective or well designed compared to more usual fare.
TLDR: Don't just grab a fortress map and expect it to make a good dungeon. Do use your DF knowledge to make dungeons better, more logical, and/or more ‼Fun‼