Why do we need functions with compact support? My question is simply, why do we need functions with compact support? Are they a ntaural consequence of including Urysohn's lemma or Tietze extension theorem-which implies the Urysohn's lemma-?
I just want to understand where do they come from so the theorems including them will be more familiar to me. 
 A: How about the Riesz(–Markov–Kakutani) representation theorem? 
A: Functions with compact support are of great use, e.g. since the following theorem holds:

Theorem Let $(\Omega, \mu)$ be a measurable space, such that $\Omega$ is a locally compact Hausdorff space and $\mu$ is a tight Borel measure. If $\nu$ is another such measure on $\Omega$ which gives the same integral on compactly supported continuous functions, then $\mu = \nu$.

This theorem paves the way for proving e.g. the existence of Haar measure on compact Hausdorff groups by the way of using oscillation.
A: Expanding on the comment above: (smooth) partitions of unity play a crucial role in differential topology and differential geometry. They let us make global certain local constructions, and in particular they can be used to prove the Whitney Embedding Theorem, one of the more famous results of smooth topology. 

(Strong) Whitney Embedding Theorem: Any $C^\infty$ manifold $M$ of dimension $n$ can be embedded in $\mathbf{R}^{2n}$. 

Another important result that partitions of unity give us is the existence of Riemannian Metrics on smooth manifolds. Riemannian metrics are important because they let us generalize a lot of what we like about Euclidean Geometry to arbitrary manifolds $M$.

Existence of Riemannian Metric: Every $C^\infty$ manifold $M$ admits a Riemannian metric $g$.

