Posting comments as an answer so this question has a formal answer...
The short answer is that for a buffer in "fundamental mode", run
Emacs is modal, and each mode selects the kind of auto-indentation that is appropriate for that mode. For example, if you edit a text file, you will be in "text mode" and lines will by default automatically respect indentation of a prior line.
When Emacs doesn't find a special a mode for the buffer you are editing, it defaults to something called "Fundamental Mode". The document string for this is:
Major mode not specialized for anything in particular.
Other major modes are defined by comparison with this one.
The way many modes handle auto-indentation is to use a minor mode called
"electic-indent-mode" (A minor mode is a variation added to a major mode like "fundamental mode").
Finally, as indicated in the comments, Emacs Wiki has more information on indentation.