Thanks for your question and congrats on using condoms when you have sex!
There are many “rumors” and myths about sex. This is a rumor. There is no particular danger with having sex when your partner is having her period, although pregnancy and sexually transmitted infections are still a risk, so condoms are key! Your cough is probably not related to having sex. It may be caused by a cold, allergies, or something else. There may be medicine that can help so it’s a good idea to make an appointment with your health care provider.