Answer:
Ribs are for protection i think and diaphragm is the muscle controlling inhaling and exhaling.
Also: the rib muscles can help the breathing process, which is useful when the diaphragm is weak, constricted, or to get an extra-big breath.
Breathing from the diaphragm makes the belly move in and out as the lungs extend downwards.
Breathing from the rib muscles makes the chest expand and rise.