Most bird bones are hollow (containing only marrow) for buoyancy to facilitate flight. However, some flightless birds, like ostriches, have only partially hollow bones.
Flightless birds have retained the ability to breathe much in the same manner as the rest of the bird class. They have a set of air sacs that are used for moving oxygen around the body. Air is moved through these sacs by the bird's respiratory muscles and can be pumped into their bones, creating a hollowed chamber which reduces its density.