Yes, the rules applies to you too. The Italian government has stated pretty clearly that all rules apply to both Italian citizens and tourists.
To be more specific, the rules for traveling in a car with non-cohabitant people are the following:
- Nobody can sit in the front seat next to the driver.
- Max 2 people per seat row, on opposite sides of the vehicle (by the windows). If the vehicle has multiple rows, it can carry more people, but only if they can keep a distance of 1m between them (more or less). So vehicles with very small extra rows might only be able to allow for one extra person, instead of two, in those rows.
- Everyone, except kids under 6yo or people with medical reasons, has to wear a mask at all times while in the vehicle.
On a side note: I would double check if 5 people from 3 different households are allowed to live in the same house. I couldn't find anything specific, but I know that for visiting friends you're only allowed to have 2 people (+ kids) go to another household.