Unlike us, snakes do not have a diaphragm so they can't cough like we do. This is one of the reasons that an RI is so deadly to them as they can literally drown in their own secretions far easier than we can. To move air in and out of their lung they have to actually use their muscles and the physical movement of their ribs. They have a vestigial second lung that as far as I know basically doesn't do much if anything for them.

I'd be very concerned about that sound/yawning and likely would be watching that snake closely. Depending on your own experience and how confident you are about diagnosing a brewing RI will help you decide if an experienced herp vet should be consulted at this point.