He is 16? That's wonderful and you have obviously taken good care of him.
At this age, like old people, he may be losing control of some bodily functions. If course, there is the possibility of a UTI, possible stones, kidney issues, swollen prostrate, etc. might not be a bad idea for a Vet exam. There are some medications that can be given that might help.
Jerry is right, you can try confining him to an area with a hard surface, if you have one, that can be cleaned. My guess is, if he is blind and hard of hearing, he may not be happy being contained.
If I were you, I would check into trying to use belly bands. Many people use these on male dogs inside that mark a lot or are having urinary problems.
Do a Google search for Belly Bands for dogs. If you sew, you could probably make your own and you might try a search to see if you can find a pattern.
Good luck with Teddy and hope you can work something out.
Our dog would pee on herself while sleeping, we put her on Proin and it seemed to help. Also, was he tested for a UTI?
Given the age there is likely little that can be done to "fix" the problem.. but there are defense measures such as dog diapers and wetting pads. A pen (large open crate really) with water proof and absorbent padding ... I know there are materials made to deal with the problem, not cure it.
Seems the "old guy" may have a few more months of life free of pain and full of love, it would be best to start to prepare yourself for the end.
Teddy had a great life and still enjoys being with you, and it sounds like you may be willing to pay in work and cost to keep him with you a little while longer.... that's how love is/works.