While Blodyavenger's answer covers how it is most likely done, here's another possibility which would allow for easy perspective switching (e.g. four or eight different directions, or some camera elevation levels):
Consider the top-down view of your map, e.g.
2 | . . |
3 | X o |
4 | . ||
5 | . . |
X marks a high pillar. For each object you store images of all possible perspectives (or use the same...), which may be arbitrary many tiles high. Now when drawing, simply start with the column or row that is on the back in the current perspective, e.g. row 1 if looking from south. After that draw the row/column the second-most to the back and so on. This way, when something is higher than one tile (stretched to the current perspective), it will simply overdraw what lies behind.
(Sorry for the lack of nice pictures, I'm not too good at applied graphics...)