Just click on an application in finder, and drag it to the dock (to the left of the separator line), and release it there.
To remove applications that aren't running from the dock, click on them, and drag them off the dock, but if they are still running, you will need to quit them first.