What you are asking is kinda impossible to do. You can't just go inside an exe and change things and there is no single type of solution as each installer varies according to how it was made. Explaining the why would take long as it has to do with how windows exe files work, assembly language, how things are packaged, etc. The only way I believe, is to make your own custom installer after capturing which files and changes the program you install is making. Keep in mind you need to know both the files and the structure which is "easy" (google msiexec for example) but also possible registry and other windows system changes.
Of course, covering such topics is outside of this site's focus, we are just a torrent site, and I would suggest searching the net on the following topics:
- Software to monitor a system for file and registry changes
- How installers work and how to create installation packages
- How to extract files from installation packages.
The above will be a good start for you but don't expect it to be easy.
I will close this thread so it won't become a chit-chat and wish you the best of luck with your task.