We haven’t tried people counting with the VL53L1X, but it looks like TI has a document (UM2600) which is titled “Counting people with the VL53L1X long-distance ranging Time-of-Flight sensor” that would be a good place to start. That can be found on ST’s product page for that sensor, along with other resources. Note that our library does not support some functionality that is likely needed for this application (such as setting a user-defined ROI, or region of interest), so you would probably have to use the API provided by ST.
For additional information, you could try broadening your search to include places like the Arduino forums, which seems to have discussions like this one. Finally, you might also consider posting a question on the ST community site.