Assuming you turned on security and don't allow anonymous users (see https://world.mendix.com/display/refguide5/Project+Security), logging in is taken care of by the application out of the box. (Your users should be System.User objects or specializations of this)
To model what happens after a user logs into your app, you can define a homepage or microflow opening a form, depending on their user role. (see https://world.mendix.com/display/refguide5/Navigation)