Ahh... always so tricky.
Well, you have a few options. Generally, I put images in an images directory in my custom module. The problem is how to get to that directory depends on your starting position. Consider the typical development installation...
http://localhost/dotnetnuke
Here, my images can be found at /dotnetnuke/desktopmodules/mycustommodule/images
When I publish to my webserver, though, the path changes to /desktopmodules/mycustommodule/images
Generally, it's recommended you reference your image using something like
<img src="~/desktopmodules/mycustommodule/images/myimage.gif">
The problem is that won't be recognized on your development machine unless you installed DNN at http://localhost (omitting the /dotnetnuke directory). So what's one to do? Well there are a few hacks like having your images in multiple locations on your local machine so the path resolves, but it seems as I write more and more modules, I just learn to live with the image can't be found X on my dev box and just wait until I push it out to staging server (or anything with a real domain) to see how it all looks. If all you do on your local machine is develop DNN modules, I'd say just put your install directly at wwwroot and not have to worry about the moving paths.