Typically the setting AUTO DETECT is sufficient. When you need to create stairs that are a little less than simple you will find these play a much larger role. Take a look at this image where we'd like to end the stair at the landing.
Now the trick to ending like this in the first place is to use a RISER not a BOUNDARY sketch line at the end.
This stair has been told not to end with a riser yet the stringer at the inside corner is desperately trying to slope, and SUCCEEDING! Also the stringer at the far end of the landing and its railing are both too high. The stair and railing sketches just need a little SLOPE attitude adjustment.
Setting them specifically to FLAT lets them behave. To apply this change you must be in SKETCH MODE to select each line segment. When one segment is selected you can alter the parameter. You cannot apply this change to multiple segments, it would be nice if we could.
So this is the result!
I should also mention that when you make a stair Revit will automatically create a railing, if you let it. As long as you never edit the sketch of the railing Revit will keep track of it. As soon as you edit the sketch for the railing Revit hands over the responsibility for the integrity of the railing sketch to you, preferring to avoid making a change to it that you may not have wanted.
Till next time here's a few parting images! Cheers!
I recently recorded a VIDEO to describe this too. You can listen and sort of watch here.