From the symptoms it can be due to urinary tract infection or prostatitis. Symptoms of UTI are frequent urination, burning sensation during urination, passing of blood in urine and even fever. The most common causes of repeated UTIs are kidney stones and diabetes mellitus. Making a diagnosis of a urinary tract infection includes performing a urinalysis test, which checks for the presence of pus, white blood cells, and bacteria in the urine, which point to a urinary tract infection. A urine culture and sensitivity is usually performed to find the exact microorganism that is causing the infection.
I hope it helps. Take care and regards.
It sounds like you may have a urinary tract infection - check in with your doctor and possibly see a urologist.