Pets hatch from eggs, but it takes time. Once your egg hatches, your new pet will be added to your inventory and you can equip it or start training it. Eggs can’t be trained or equipped.
You can find eggs on vendors, as loot, earned as badge or quest rewards, or purchased from the Crown Shop.