A header file contains declarations of functions and objects you can use. The file iostream is a header file. When you write #include <iostream>, the compiler copies that file's contents into your program before compiling.
Header files end in .h or have no extension. Standard library headers like iostream have no extension. Later you will create your own header files to organize large programs. Think of header files as instruction manuals.
The compiler reads the manual to learn what cout can do, then uses that knowledge to translate your code. No manual means no translation.