Just discovered my first necromancer tower accidentally, and immediately got spotted by the fuckton of undead in there. I was swarmed and killed in two turns, I didn't even have the time to get proper armor and skills. I'm getting pretty frustrated by this - is there something I can edit my skills with? And if yes how? Outside of modding.
My feeling is part of why you died is stats (in your skills and attributes), part can be equipment, part is knowing how NPCs fight, what type of NPC, and if should you even be there (why not? Death will find us soon enough).
The short term answer to your skill/attribute issue is to powerlevel. Find small animal, have several shields equipped. Get it to attack you. Macro this. Hopefully when doing this you added no points to shield/dodge/observer during character creation as these 3, which are arguably the most important skills, will "naturally" grow during the powerleveling. Your attributes will all grow to their maximum as well. Big defensive stats will keep you alive. Big offensive stats can now be grown leisurely. Equipment is no longer an issue.
The long term answer is to learn generally what you can do, and what you are not yet strong enough to do, avoid those things, until you can. Dying helps tell you where this boundary is, but sometimes you'll just die repeatedly and learn very little. The persistence of unreflective losing is useless.
Combat is just stat comparison. There are not a large number of tactics as lone NPCs rush wildly into a fight, and groups swarm around their target(s). This is where powerleveling and savesumming become useful learning tools, not an end, a means to know where, because now you can begin to approximate what is good enough, particularly if for some reason your character has not grown progressively to meet the stat strength of your opponents. Obviously if you powerlevel a huge untouchable monster character, the only thing learned is you can't be killed. Sometimes what's useful is making an experimental character (or are all characters experiements?) who can be used fight and die against, say a necromancer's tower. But here you can also try savescum to redo the fight with slightly higher stats. However you want to do this works, but powerleveling is a faster way to see this through. Incrementally increase stats by one level up, say adequate to skilled, or skilled to proficient. Over time you learn to not powerlevel and savescum, that the average soldier is very killable at a certain low-mid range skill, that elite melee requires comparable or to be shot from a distance, undead who swarm will kill a base level (2000) legendary once they swarm.
Playing strict rogue has a very steep learning curve since what happened one adventure may not repeat in its specifics until several adventures later and by then perhaps you no longer remember why you were even there or what was done that time before. For this reason, I would try everything.