Consider a bag of water floating in water. There are two forces - gravity and buoyancy force. The two are equal and opposite. You know this because a bag of water sits quietly without acceleration. So the buoyancy forces from the water outside press on the bag strongly enough to hold it up against the weight of the water pressing on the inside.
This is much like a mass sitting on a table. Somehow the table supplies an upward force equal and opposite to gravity. One difference is that people explain why pressure leads to a buoyancy force, which is often confusing. For the reaction force of a table, people don't try to explain it until more advanced courses.
Suppose you repeat this with a bag of the same size and shape full of air. The weight is much less, but the buoyancy force doesn't change. The buoyancy force is determined by the size and shape of the bag.
Repeat again with situation B. The bag is big enough to hold 100 g of water. You put a 100 g object in that is the same density as water. This means it has the same volume as 100 g of water. It just fills the bag. It floats just like it had water in it.
Repeat with situation A. This time we use a 100 g object that is half as dense as water. It has twice the volume of 100 g of water. Half the object sticks up out of the bag above the water. The buoyancy force comes from the shape of the bag, so it is strong enough to support a 100 g object. The downward force is weight of the 100 g object. So the object floats half out of the water.