The alveoli are surrounded by capillaries. Here, oxygen rich air passes through the alveoli walls and into the blood.
After absorbing oxygen, the blood leaves the lungs and is carried to your heart. Your heart then pumps it through your body to provide oxygen to the cells of your tissues and organs.
As the cells use the oxygen, carbon dioxide is produced and absorbed into the blood. Your blood then carries the carbon dioxide back to your lungs, where it is removed from the body when you exhale.