How to modify template.php in bootstrap theme, to add a class tag to menu li tag?
Whenever in a theming guide you see a reference to template.php without a context, it should (and in official documentation does) mean the template.php in the root directory of a theme / subtheme you are developing.

In your case it means ./bootstrapMYSUBTHEME/template.php

Never hack your base theme. Your changes will be lost and gone if someone will decide to upgrade it. And if you will upgrade it, you will have to re-write them into new version after each upgrade. Waste of time, subthemes are there exactly to avoid that burden.