Consider a single hydrogen atom.  The normalized ground state electronic wavefunction is given by
$$\psi_0(\mathbf x)= \frac{1}{\sqrt{\pi} a_0^{3/2}}e^{-r/a_0}$$

This system models an electron moving in the electrostatic potential created by a single proton at the coordinate origin.  The Hamiltonian for this system is
$$H_0 = \frac{\hbar^2}{2m}\nabla^2 - \frac{e^2}{4\pi \epsilon_0 |\mathbf x|}$$
$$H_0 \psi_0 = E_0 \psi_0, \quad E_0 \approx -13.6\ \mathrm{eV}$$

---

Now consider the Hamiltonian corresponding to *two* protons, at positions $(0,0, \pm \delta)$:

$$H = -\frac{\hbar^2}{2m}\nabla^2 - \frac{e^2}{4\pi\epsilon_0 |\mathbf x - \delta \hat z|} - \frac{e^2}{4\pi\epsilon_0|\mathbf x+\delta \hat z|}$$

If $\delta \gg a_0$, it would be reasonable to expect that $\psi_0(\mathbf x-\delta \hat z)$ and $\psi_0(\mathbf x+\delta \hat z)$ would be approximate eigenstates of this Hamiltonian.  If the electron is localized around the proton at $(0,0,\delta)$, for example, then we would have

$$H \psi_0(\mathbf x-\delta \hat z) = \left(-\frac{\hbar^2}{2m} \nabla^2 - \frac{e^2}{4\pi \epsilon_0|\mathbf x - \delta\hat z|}\right)\psi_0(\mathbf x - \delta \hat z)- \frac{e^2}{4\pi\epsilon_0|\mathbf x+\delta\hat z|}\psi_0(\mathbf x-\delta \hat z)$$

$$= E_0 \psi_0(\mathbf x - \delta \hat z) - \frac{e^2}{4\pi\epsilon_0|\mathbf x+\delta \hat z|}\psi_0(\mathbf x - \delta \hat z)$$

Looking at the latter term, if the electron is exponentially localized to within $a_0$ of $(0,0,\delta)$, then the potential can be approximated to zeroth order in $a_0/\delta$ as 
$$-\frac{e^2}{4\pi \epsilon_0 |a_0 + \delta|} \approx 2E_0 \frac{a_0}{\delta}\rightarrow 0$$

$$\implies H \psi_0(\mathbf x-\delta \hat z) \approx E_0\psi_0(\mathbf x-\delta \hat z)$$

To lowest order, the ground state of the system is twofold degenerate with energy $E \approx E_0$.  Because the potential possesses parity symmetry, we can choose the two linearly-independent ground state wavefunctions to be

$$\psi_{\pm} = \frac{\psi_0(\mathbf x-\delta\hat z) \pm \psi_0(\mathbf x + \delta \hat z)}{\sqrt{2}}$$

---

Of course, this approximation is very rough if $\delta$ is not vastly larger than $a_0$.  In that case, we can look at the first-order correction to the (initially degenerate) ground state energy.  Rather than evaluating it outright, we can simply argue in a very handwavy way what will happen.  A more careful analysis would of course utilize [perturbation theory](https://en.wikipedia.org/wiki/Perturbation_theory_(quantum_mechanics)#First_order_corrections).

Note that $\psi_+$ is comparatively large in between the two protons while $\psi_-$ is comparatively small - indeed, $\psi_-$ must vanish anywhere on the $z=0$ plane.  As a result, $\psi_-$ is more localized around each proton while $\psi_+$ is more localized in between them.

Correspodingly, the potential energy of $\psi_+$ should be *more negative* than the energy of $\psi_-$ because it "sees" the potential from both protons.  Furthermore, the *kinetic* energy of $\psi_-$ should be *more positive* because, being antisymmetric about $z=0$, it changes more rapidly near the origin, and kinetic energy is proportional to $\psi''$.  

As a result, the first-order correction causes the energy of $\psi_+$ to decrease and the energy of $\psi_-$ to increase.  Therefore, the initially degenerate ground state splits into a true ground state $\psi_+$, called the *bonding orbital*, and a low-lying excited state $\psi_-$, called the *antibonding orbital*.

A careful analysis shows that $E_-<E_0$ and $E_+>E_0$, with the splitting proportional to $a_0/\delta$.  This indicates that as we bring the protons closer to one another, the energy of an electron in the $\psi_-$ orbital decreases.  We can interpret this as an attractive force which pulls the protons closer together.  Of course, this neglects the electrostatic repulsion between the protons; if they get *too* close together, this repulsion overcomes the attractive interaction mediated by the electron.  

The system achieves equilibrium with the attractive force (due to the electron) and the repulsive force between protons are in balance.  The electron forms a bond with a well-defined bond length, and we have created a $H_2^+$ ion.  This is, in broad strokes, how atoms and molecules bind to one another.