To make it work with Single Train Unit mod (discussions for that mod are closed) - should edit scriptss/entity.lua, in Entity.PlaceWagon function, in local wagon = surface.create_entity add new parameter raise_built = true
This will make ZElecticVehicles to properly register Single Train Unit locomotives