Road trips are awesome fun. I am also very much the introvert on road trips and love the solid blocks of "zone-out" time.
This sounds like the type of situation that is just a preference. It is something that each of you can easily decide to do or not do during this trip without changing your whole life. It isn't like being forced to travel with a person who drives dangerously or who won't wear deodorant or who constantly tells stories about how great the other political party is, so neither of you is likely to be insulted or offended by the mention of the issue ... if you communicate ahead of time.
Direct is best for those types: The most direct way to deal with this situation is to talk about it clearly ahead of time. Explain how you feel then ask the other person how they feel. Then compromise and be a thoughtful person. It sounds like a very common introvert vs. extrovert situation:
"While I enjoy spending the time on trips catching up and getting to know you better, I also taking time on road trips to zone out to some music and just meditate quietly on my life. So if you see my grab my headphones during a part of the drive, don't take it as something about you or your conversation. This is just how I recharge, look over how my life is going, and think about the future. It is a great time for me to get my thoughts together so I can be more present during the times when we are talking."
Eh, something like that. And as a hint, the start of a road trip and when some interesting landmark or cool situation is coming up are the times when chatty people are most likely to seek and enjoy the conversation. Start off the first bit of the trip talking and catching up, then take some zone-out time for a stretch.
As you approach a stop or landmark, take off the headphones and strike up a conversation about it. The other person will love you for it ... not having to be the one starting all of the conversations after you just told them about how you like to zone out ... that is a thoughtful thing and they will appreciate it.
When the other person knows how you feel ... and sees that you are respecting how they feel by taking some non-headphone time ... it will smooth things out.
Happy trails!
And since you didn't mention if this is a friend or relationship partner, here is the "relationship partner" answer:
If this is your relationship partner, it is even way more important that this works out. Being able to communicate about these things clearly and find a solution together instead of going into the typical "fix it myself mode" is one of the keys to a great relationship and a habit to start early.
Also, if this is your partner, then this isn't a "just a preference" situation that I described at the start. This is the chance to show that you value their thoughts and want to share ideas and plans. If you ignore those, you will leave a mental "crack in the windshield" of your relationship that is hard to fix.
Just my 2 cents...