Okay here's pictures for anyone with this issue (other than op who is getting lots of other useful feedback rn). Below is a chart of how your lung capacity works.
Here's a handy chart with those points circled.
Tidal volume is how much air moves in and out of your lungs when you're just breathing normally at rest. Exact amounts vary, but it's a fraction of your total lung capacity.
Vital capacity is how much air you can possibly move in and out of your lungs as an alive person.
Residual volume is how much is in there if you feel like you've squeezed every possible molecule out. It's never zero, because your lungs are connected to the insides of your ribs, which are notably kind of round. If your lungs are actually empty-empty of air, you've collapsed your lungs and are probably dead.
So the thing is. As a mammal that breaths air. Your body does Not want you to damage your lungs. So breathing in to the top of your vital capacity? Kind of sucks! It can be a nice stretch occasionally but holding your breath there feels Bad. For me it's kind of stressful pressure, and my body wants to breathe it back out.
Similarly, being at minimum capacity Feels Bad! Because your body thinks you're gonna die of oxygen deprivation! So don't go there either!
So if you're doing a breathing exercise, you're not aiming for max and min. You're aiming to slow down hyperventilation breaths (hence the counting and, critically, the holding of your breath) and sort of trick your parasympathetic nervous system into activating. "If we were panicking because of a tiger, we'd be breathing really fast, but we're breathing slow, so we must not be panicking about a tiger, so I can calm down now."
Personally, during a breathing exercise, these are the areas I aim for:
This (theoretically) doesn't make your body More Stressed by adding in mammal animal fear of death.
Personally, I don't find holding my breath to be very necessary or useful other than settling into a meditation rhythm, but I can get that rhythm by reciting poetry too.
If your back and ribs hurt, your intercostal muscles (the ones that move your ribs in and out) are either Hella Tight or Hella Weak. Based on OP's descriptions, I think tight. If they want the exercises to help (which is not necessary and completely optional), I'd recommend practicing breathing like they're about to fall asleep while they are already calm, to see how those parts feel when they're not tense as hell.
But critically, breathing exercises are supposed to help like, moderate distress and dissociation. They only work if there Is No Tiger. If you're actively in a seriously distressing environment or experiencing Fear For Your Life levels of fear, breathing exercises will not help, because your body's gonna be like. "But there is in fact a Fucking Tiger." And if you try to tell it there's no tiger often enough while there is, in fact, a tiger (or other equivalently life-threatening fear, like, say, a medical professional telling you what to do when you have medical phobias), your body is going to stop believing you. You will in fact counter condition yourself and associate breathing exercises with Bad Things, and they will make you feel worse.
Fixing that is a whole bitch and a half. I'd start by taking one gentle breath, slightly larger than usual, like a yawn, and exhale immediately back to somewhere comfortable, when you're 100% safe and comfortable. Yes, that small. Gotta start that small to rebuild your body's trust in you.
But also breathing exercises are optional. If you don't like'em, fuck'em.