Trying to reconcile the metaphysics of Newton and Leibniz, Kant proposed that space and time exist at one level of reality but not at another. The value of this depends on the nature and credibility of Kant's Transcendental Idealism (http://www.friesian.com/kant.htm#idealism). Such a theory, however, makes possible a Kantian interpretation of quantum mechanics (http://www.friesian.com/space-2.htm#kant).
What space and time are:
Kant proposes that space and time do not really exist outside of us but are "forms of intuition," i.e. conditions of perception, imposed by our own minds. This enables him to reconcile Newton and Leibniz: agreeing with Newton that space is absolute and real for objects in experience, i.e. for phenomenal objects open to science, but agreeing with Leibniz that space is really nothing in terms of objects as they exist apart from us, i.e. with things in themselves.
How space is known:
Kant does not believe that the axioms of geometry are self-evident or true in any logically necessary way. They are logically "synthetic," which means that they may be denied without contradiction. That is a significant claim because it would mean that consistent non-Euclidean geometries are possible (which would involve the denial of one or more of the axioms of Euclid, as Bolyai, Lobachevskii and Riemann actually accomplished). Nevertheless, Kant did believe that the axioms of geometry are known "a priori," i.e. that they are known to be true prior to all experience, because Euclidean axioms depend on our "pure intuition" of space, namely space as we are able to imaginatively visualize it. Only if non-Euclidean space can be visualized would Kant be wrong.
The cosmology of space and time:
Kant does not think we can know, or even imagine, the universe as either finite or infinite, in space or in time, because space and time are only forms of perception and cannot be imagined or visualized as absolute wholes. The universe, as the place of things in themselves, is not in space or in time and so is neither finite nor infinite in space or in time. Thus there cannot be an a priori, rational or metaphysical, cosmology. Kant's Antinomies are intended to show that contradictory metaphysical absolutes can be argued and justified with equal force, meaning that neither can actually be proven. It can be argued however, that Einstein answered Kant by proposing a non-Euclidean (Riemannian) universe that is finite but unbounded (i.e. without an edge).