Agreeing. Red flag. The fact he first acted like he didn't know...Red flag. If I were in a relationship or marriage, and my partner was doing this? I would be very upset and unhappy. There's a major difference between being nice to someone and flirting with them. Being nice to someone is smiling at them, saying hello, asking how their day was. Doing small random acts of kindness. Not ya know, saying they have a nice tush. That's not being nice, that's flirting and also inappropriate in a work setting.
I am deeply sorry this is happening, I can only imagine how you feel. I can't tell you what to do, but from reading this it sounds like you have valid reasons not to trust him. Our instincts are typically correct. Trust yourself.