Don't confuse model IDs with vehicle IDs

There are two similar parameters that appear in various functions: modelid and vehicleid.

The vehicle ID (vehicleid)

Each vehicle has it's own unique ID number (starting from 1) which can be used to perform actions on that certain vehicle, such as changing it's color. The vehcle ID is assigned to a vehicle upon creation. Vehicles can be created by the following natives:

A player's vehicle ID can be retrieved using GetPlayerVehicleID.

The model ID (modelid)

All in-game models (this includes vehicles, skins, buildings, objects, roads, weapons, etc) have an unique identifier which is defined in the game files. This identifier is known as a model id (or, model index as R* calls it). You can obtain the model ID for a vehicle using GetVehicleModel.

In conclusion

It is important to pay attention to the details provided. Most documentation pages deliberately use different names to make it easy to separate both vehicle and model IDs.

Note: Although not explicitly stated, the same story applies for object IDs, pickup IDs, actor IDs, and the like.