Geofencing is the term to search for. Here's an example: https://fossdroid.com/a/nexttracks.html
(don't know if it is any good, it was just the first I found)
Tasks is able to set reminders when entering or leaving a location. Just add a task with the + on the homescreen, set a location (enable permission for Tasks), click on the bell besides that and define other parameters like name etc. Tadah.