I had this happen with my wife's Sienna actually. It ended up being the door switch (the one that tells it the driver door has opened and closed). Check whether your door ajar light comes on when you open the driver's door. The theory of operation seems to be that the headlights remain on until 20 second after the drivers door has been opened and closed. With a bad switch, it seems to think the driver is still sitting in the vehicle and leaves the headlights on. It only took a $14 switch and about 10 minutes to swap it, but I probably spent an hour messing with things before coming up with a plausible theory (proved right in my situation).
The switch is only connected by one wire and grounds through the body, so good ground is necessary. When you test, make sure you put the screw in or your switch will probably not work.