Here's how it works.
http://lodev.org/cgtutor/raycasting.html
A doom engine is a little more involved and requires BSP trees, more clipping/culling and something closer to actual 3d (floors and ceilings with variable heights, geometry that doesn't fit onto a grid).
Both of the games used 2d sprites for enemies rather than 3d models, so you could draw all of the graphics with paint rather than a modelling tool which would probably be a significant time saver.
A psuedo 3d wolfenstein clone written with a reasonably optimized raycaster would probably outperform a unity version quite significantly. I don't know how well suited unity is for having 3d game entities represented by flat textures instead of 3d models for example.
* http://en.wikipedia.org/wiki/Binary_space_partitioning
I keep thinking about the Malcolm Gladwell "Ten thousand hours to expertise" idea, and for Carmack to be looking at this sort of stuff at the age of 22, he basically had to eat sleep and shit computer graphics for years and years on end before he could be in a position to apply this to a computer game.
2) Game logic - a game like Wolfenstein has basically planar gameplay, you can't jump or aim up and down. You could play the same game in top-down view on a grid of squares.
3) Rendering - it should take you at most a day to write a Wolfenstein like renderer. Might be scary if you've never done 3D before, but it's a great starter project.
In any case, heretic and hexen actually let you look up and down. Crispy Doom (among others) have backported this feature and hook it with mouse aim.
Try shotgunning someone high up and far far away. Either there's a distance limit to auto aim, or it's just really damn picky about how perfectly you're lined up. Most of your shots will hit the wall below him.. it can be frustrating.