To trade pets with other players, click on the player, then click on the name tag.

A menu will appear, select Pet Trade.

Pet Trade menu

Drag the pet(s) you wish to trade from your pet slot into the trade window.

Pet Trade window

Press Ready to confirm the transaction. Your trade window will grow blue.

When both players are ready the transaction will be complete.

NOTE: Always double check if the pets your trading (yourself and the other player) are correct before you confirm. Don't be Scammed!