Earlier quoted context omitted.
It provides shadow and protection from rain above the entrance. It's a pretty common design.
Okay but why not separate small roof over entrance? This design is making wall more complex (now whole roof overhangs over entrance) for not all that much gain.
And it looks very different, I wouldn't do it at least.