Why did Moses write in the third person in the first five books of the Old Testament?

Never got a chance to ask him. But maybe because he didn’t have an ego problem. 

But just because it’s written in third person doesn’t mean Moses didn’t write it. There are multiple ways of writing a story and Moses wrote it this way. Just like some books in the New Testament are written.