The temporal origin of dentate granule neurons dictates their role in spatial memory