The superconducting transmon qubit as a microwave resonator