Here are a few non-UC reasons for losing muscle. I hope none of them apply to you. It's actually a normal part of aging to lose some muscle starting after age 30.
www.healthline.com/symptom/muscle-wastingMalabsorption is #16 and related to Crohn's but could be UC-related.
If you've seen it happen rapidly then I would start using hand weights and/or go to the gym to increase your muscle mass while also making sure you are eating enough protein.
If your annual physical is coming up ask your primary doctor about
it.