Hi
If you are coughing up blood then yes you should go and see your doctor without delay so he can rule out any nasty diseases. Try not to leave it too long to go and see him.
It may not be serious, could be something as simple as an infection that has spread, maybe in your tonsils that are bladly inflammed and casuing you to cough up the blood (just an example)
But as a perosnal general rule, any sign of blood when coughing a person should go to their doctor as soon as possible.
Good luck