With some stipulations.
First, the PHB on page 198 gives good insight into mounted combat. There are two sections I'd like to call attention to:
While you're mounted, you have two options. You can either control the mount or
allow it to act independently. Intelligent creatures, such as dragons, act
For domesticated mounts, which covers most use cases:
[A controlled mount] has only three action options: Dash, Disengage, and Dodge.
The same section gives rules for Independent mounts. This addresses the Dragon example:
An independent mount retains its place in the initiative order. Bearing a
rider puts no restrictions on the actions the mount can take, and it moves and
acts as it wishes. It might flee from combat, rush to attack and devour a
badly injured foe, or otherwise act against your wishes.
Thus, yes, a dragon being used as a mount can use its breath attack.
However, the PHB implies that the dragon, being explicitly listed as intelligent, would not be under the player's control for its turn -- it would be controlled by the DM.
Although the dragon may be open to taking suggestions (as dragons rarely take orders), and may very well agree that a breath attack would be a good idea, the player does not have final say in what the dragon does or does not do on its turn.