When you sign up to Waze Carpool, you allow the app to use commute pattern information from your Google Account Location History to match you with riders on similar routes at similar times. When you move or change your place of work, Google location history updates automatically after a few drives to the new location.
Read more about Google Location History here.
A note for iOS users: If you set your Home and Work in Waze, Waze Carpool will use that info to help figure out your daily carpool route. You can update it at any time in the app.