Say another person wishes to buy some of your mobs and gives you the appropriate currency in exchange for some of your mobs. To do this, you catch them with a fishing rod and then type /transfercaughtentities (/tce) <player>, to start a request to transfer them to the other player.
Take note that when accepting this request it will overwrite your own caught entities list, so make sure you don't have any you're currently moving beforehand.
If you catch any tamed animals you can transfer them to another player with this command.