What does it mean when a guy remembers random fact about a girl?

There is this guy who is my friend, however, we rarely talk to each other as we do not meet that much. However, he remembers a lot of things said in a random conversation. For instance if I say I like that teacher because he has a nice character, and then a year later that teacher starts teaching him, the next time that we talk, he would tell me "that teacher whom you liked his character - yes he is a good teacher and has a nice character also"

He also remembers details like for instance if we met once between the classes and told him which lesson I had, two weeks later he still remembers which lesson I am having at that time.

How come one remembers things that we've had long time ago and was just a random talk? Once I heard that if a guy remembers details about a girl, it can mean that he likes her. Do you think he likes me?

Also, once I told him that I saw him somewhere and he told me that he didn't see me and maybe he will see me some other day. Yesterday, he said that he saw me and he thought that I didn't recognize him (I saw him too but wasn't sure it was him, so I kept going but I saw him looking at me and doing a half cute smile)

Is he doing this just to show me that he is interested or what?
What does it mean when a guy remembers random fact about a girl?
Post Opinion