I run into this error by trying to pass elements from a Custom Page to a Power Automate flow.
How to do this is described here :
However, in the process of achieving it, I ran into the error "The JSON function cannot serialize tables / objects with a nested property called '_ownerid_value' of type 'Polymorphic'"
It is clearly stated that the JSON function can not serialize lookup fields like ownerid, but it could have been the same with other Polymorphic fields.
So, long story short, you have to use the option :
And now it works ! !
Hope it helps you !