Some dealers plain suck, I had a similar experience with my Jeep YJ that was dying while driving. They tried to blame the alarm because it would kill the starter when triggerd. They never clued in that the starter is not in use while driving, and once it would die, the starter would work, but the engine would not start.
The crooked ones always try to screw you with any excuse possible. Most people either have one of those stories or know someone that does.
I guess we know where you will not buy your next Xterra.