You are, I think, confusing HD (hard drive) space and RAM (memory.)
RAM, or Random Access Memory, or just Memory, is temporary*. It is, however, very fast. When you load a program or document, much of it will probably be in RAM, so it can run faster. Generally, you have less memory then you do hard drive space. For instance, my iBook came with 256MB (megabytes) of memory. It also came with 40GB (gigabytes) of hard drive space. 1 GB = 1,024 MB.
Hard drives are slower. One big reason for this is that they [hard drives] are mechanical, unlike memory. However, stuff on a hard drive is stored permanently**, unlike stuff in memory. And hard drives generally store far more then memory. For these reasons, most of your programs and documents as well as the operating system is stored on the hard drive, and only placed into memory when needed.
There's one more concept to understand: virtual memory. Mac OS X (pronounce it Mac-Oh-Sss-Ten) makes extensive use of virtual memory. When the computer takes a special chunk of hard drive space and acts like that chunk of hard drive space is memory, that's called virtual memory. Virtual memory is far slower then real memory, but since hard drives are generally so large, you can pretend to have far more memory then you really do.
* Temporary; goes away when the computer is shut down or restarted, and can also be removed manually.
** Permanent; does not go away when the computer is shut down or restarted, but can be removed manually.