If the Pokémon you are Riding evolves from a battle, he/she/it will retain their unevolved sprite until you stop Riding them.
Here's an example with my shiny Riolu: Was grinding Kanto's Victory Road, training Riolu with the Experience Share while Riding on him. I reached level 50 and triggered his evolution into a Lucario. He still appeared as a Riolu in the overworld until I disembarked Lucario.
The image is showing that I'm Riding a Riolu, despite not having a Riolu in my party:
Here's an example with my shiny Riolu: Was grinding Kanto's Victory Road, training Riolu with the Experience Share while Riding on him. I reached level 50 and triggered his evolution into a Lucario. He still appeared as a Riolu in the overworld until I disembarked Lucario.
The image is showing that I'm Riding a Riolu, despite not having a Riolu in my party: