I want to override the right-click menu in a RichTextBlock or a TextBlock, I have been searching for the solution and tried using RightTappedEvent, but it did not fire when right tapped a chosen text, but it fired when I right tapped in elsewhere in the control.

Yes, you can use
ContextFlyoutto change it.You can add the
ContextFlyoutto custom your menu.The code shows how to add the custom menu.
See UWP How to custom RichTextBlock right click menu
All code is in github