Along time ago I suggested the code be essentially customer driven. I showed a way how to calculate the nearest driver to the customer. This keeps the app less complex. The app need only to display the customer location. You decided you also had to show the driver locations. I explained that is not necessary.
The model I suggested didn't allow the customer to select a driver. It was done by the app. I don't think it advisable or needed to allow she/he to get choosey. Let the app select.
Let the code determine the nearest available driver. I showed one way a long time ago.
using the CloudDB. You are now using a FirebaseDB which behaves similarly by not exactly in the same way.