While you don't have to declare prescription medication, there are limits on both prescription and non-prescription medication.
Some prescription meds are not allowed. Some OTC meds are not allowed. (Example, Vicks inhaler for stuffy noses is not allowed.)
There are also limits as to how much you can bring in. You are allowed a 30 day supply of prescription meds and a 60 day supply of non-prescription meds and vitamins. If you want to bring more, you have to fill out a special customs form prior to your journey, send it to Japan, and wait for it to return. Otherwise, more than the allowed amount could be confiscated and you could be arrested.
This US State Dept page has information on this as well as a link to the official Japanese site--in English.
https://jp.usembassy.gov/services/importing-medication/
Food and water is safe in Japan. Just follow the same practices as you would anywhere else.