there are actually 2 ways of doing it.
but first you need to change the way you think about the browser. Don't think of it as 'exiting' like closing a computer browser, just think of it as 'leaving'.
1 - When you're done with the browser, press the home key.
2 - you can press the menu button and then tap on X to close every open window, when you reached the firs page just press the back button and go to home page .
Android doesn't really ever close the programs you open, you can try using a task manager if you really feel the need to close the program, but some people don't recommend it .