Allay in a Bottle

Catching an allay
Right-click an allay with an empty glass bottle: it goes into the bottle. A stack of bottles works too: one is used and the full bottle goes into your inventory.
You can catch a wild allay, or one that follows you. An allay that follows someone else (they gave it an item) can't be caught: "This allay follows someone else."
Everything stays with it: the item it holds, what it carries, its name and who it follows. The bottle says what it's holding and carrying, and a named allay's bottle carries its name ("Sparky in a Bottle").
Letting it out

Use the bottle:
- on a block: the allay comes out in front of the side you click;
- in the air, or on an animal or another allay: it comes out just in front of you.
You get the empty glass bottle back. Where there's no room for it, it stays in the bottle.
What you click comes first: a door opens, a chest opens, a lever flips, an Allay Lodestone shows its range above your hotbar, a villager trades, an item frame takes the bottle, and the allay stays in. To let it out on such a block anyway, sneak while you click (not on a block of these mods, such as a vault or an Allay Lodestone: sneaking there opens its settings). Sneaking doesn't help on a villager, an item frame or a horse: click the ground beside it.
Giving an allay an item
An allay takes only what's in your main hand. Right-clicking one with an empty hand never hands it your shield or whatever else is in your off hand (in the normal game it would). A name tag or a lead in your off hand still works.
It can't be drunk, and a brewing stand won't brew it (gunpowder would make it a splash potion and the allay would be lost). Craft it with a lodestone into an Allay Lodestone: only an allay that holds and carries nothing goes in, so let it out and take its item first.