For the door to stay closed, the latch needs to fully extend within the strike plate's hole. Adjusting how the door latch and strike plate meet can resolve issues where doors won’t stay closed.