The urinary system is made up of the kidneys, ureters, bladder, and urethra. It collaborates to generate, transport, and eliminate urine from the body. A urinary tract infection occurs when harmful bacteria enter your body by any opening in the urinary tract, causing destruction and inflammation.