This might be a stupid question but given (my brief understanding of) how the fediverse works, would a fediverse version of a messaging app work? As a potential WhatsApp or Telegram replacement? Or is there one already?
The fediverse is not build for messaging. It is an inherently public model of everything. "Private" messaging is possible, but more often referred to as "direct" messaging, because every server admin can read your texts, as activity pub (the foundation the fediverse is based on) currently has no capability for end to end encryption.
Matrix is propably what you are searching for, as the other commenters pointed out. Alternatively may XMPP, but from what I've observed Matrix is a lot more active atm