There are some conventions when using contributed modules and/or themes. Most users would want to place them in modules and themes folders.
Don't ever do that! Never place modules or themes in these directories!
Everything added to a fresh Drupal install should go somewhere in the sites directory:
- Contributed modules (from drupal.org) should go in
sites/all/modules/contrib - Project custom modules should go in
sites/all/modules/custom - Contributed themes (from drupal.org) should go in
sites/all/themes/contrib - Project custom themes should go in
sites/all/themes/custom
Note that if you have a multisite environment, you could place somes of the modules/themes:
- in
sites/default/.. - or
sites/example.com/.. - or
sites/anotherdomain.com/.. - and so on..
... depending on your configuration.
Note that using a contrib and custom directory convention will help you find out which modules are contributed by the drupal community and which you have developped specifically for the website.
This will allow you to update more easily your websites as the only directory you will need to preserve will be sites/*.