The metric measures lengths in various directions, and also angles between various directions. For example if $\vec{e}_{(1)}$ is the basis vector in the $x^1$-direction, it will have length (squared) given by
$$ \lVert \vec{e}_{(1)} \rVert^2 = g(\vec{e}_{(1)}, \vec{e}_{(1)}) = g_{11}. $$
If we also have the basis vector $\vec{e}_{(2)}$ in the $x^2$-direction, then the angle $\theta$ between these vectors obeys
$$ \lVert \vec{e}_{(1)} \rVert \cdot \lVert \vec{e}_{(2)} \rVert \cos\theta = \vec{e}_{(1)} \cdot \vec{e}_{(2)} = g(\vec{e}_{(1)}, \vec{e}_{(2)}) = g_{12}. $$
So far we haven't made any mention of transforming coordinates. Now coordinate transformations are something we'd like to be able to do, and the rule for the metric (or indeed any rank-(0,2) tensor) is
$$ g_{ij} = \sum_{\hat{\imath},\hat{\jmath}} \frac{\partial x^\hat{\imath}}{\partial x^i} \frac{\partial x^\hat{\jmath}}{\partial x^j} g_{\hat{\imath}\hat{\jmath}}. \qquad \text{(all coordinate transformations)} $$
If the hatted coordinate system is normal Euclidean space with normal Cartesian coordinates, $g_{\hat{\imath}\hat{\jmath}} = \delta_{\hat{\imath}\hat{\jmath}}$ and we are left with
$$ g_{ij} = \sum_{\hat{\imath}} \frac{\partial x^\hat{\imath}}{\partial x^i} \frac{\partial x^\hat{\imath}}{\partial x^j}. \qquad \text{(Cartesian hatted coordinates only)} $$
But this is just a rule for transforming the metric from one coordinate system to another. The real use of the metric is to calculate lengths and angles in a particular coordinate system (as above), or to describe the local geometry of space(time) in a concise, abstract way (in which case you don't even find its components in any particular coordinate system).
As you may know, the metric tensor is a bilinear 2-form. It accepts two vectors from vector space $V$ and gives back a real number in $\mathbb R$. It is linear in both arguments, hence 'bilinear'. The metric tensor is interpreted as a linear operator in the sense that it maps one of its arguments (either one; doesn't matter because it's symmetric) to a dual vector in $V^*$. This dual vector is interpreted as a functional on $V$ (the traditional definition of the dual space of $V$), which acts on the second vector to give a scalar value. So $g$ is a linear map from $V$ to $V^*$. When you write $g$ as a matrix and operate on a column vector $v$, transpose the resulting vector to make it a row vector and you have the dual vector $v^*$.
From a general point of view, the metric tensor is a rank 2 tensor, specifically a rank $(0,2)$ tensor. In general, a rank $(n,m)$ tensor is a multilinear functional which acts on an ordered collection of vectors in $V$ and dual vectors in the dual space $V^*$. For a vector space $V$ over a field $\mathbb F$ (usually $\mathbb R$ or $\mathbb C$), a tensor $T$ is a multilinear map of the form
$$ T : V^m \times V^{*n} \rightarrow \mathbb F .$$
Rank $(0,2)$ tensors over the real numbers, like $g_{\mu \nu}$,
$$ g : V \times V \rightarrow \mathbb R$$
are particularly interesting as they often appear in mathematics and physics. This is because they define inner products. The inner product between two vectors $\begin{pmatrix}a_1\\a_2\end{pmatrix}$ and $\begin{pmatrix}b_1\\b_2\end{pmatrix}$ in an inner product space $V$ is
$$\begin{pmatrix}a_1\\a_2\end{pmatrix} \cdot \begin{pmatrix}b_1\\b_2\end{pmatrix} = \begin{pmatrix}a_1&a_2\end{pmatrix} \begin{pmatrix}A_{11}&A_{12}\\A_{21}&A_{22}\end{pmatrix} \begin{pmatrix}b_1\\b_2\end{pmatrix}$$
where $\mathbf A$ forms a symmetric positive-definite matrix (symmetric with positive real eigenvalues). By convention we normally write vectors in $V$ in an orthonormal basis, which is a basis that diagonalises $\mathbf A$ to the identity matrix, and so we usually omit $\mathbf A$ entirely when taking inner products because of this orthonormal choice of basis:
$$\begin{pmatrix}a_1\\a_2\end{pmatrix} \cdot \begin{pmatrix}b_1\\b_2\end{pmatrix} = \begin{pmatrix}a_1&a_2\end{pmatrix} \begin{pmatrix}b_1\\b_2\end{pmatrix}$$
when the vectors are written in an orthonormal basis.
These inner products $\mathbf A$ are basically the same thing as metric tensors $g$. Two terms for one concept. Of course in pseudoriemannian geometry, $\mathbf A$/$g$ need not be positive-definite. It is clear how $\mathbf A$ should be interpreted as a linear operator though, right? It maps the vector $\mathbf b$ to its dual vector $\mathbf b^*$ like so:
$$\mathbf b^* (\mathbf a) = \mathbf a \cdot \mathbf b \tag{definition of dual vector space $V^*$}$$
$$\begin{align}\mathbf a \cdot \mathbf b &= \begin{pmatrix}a_1&a_2\end{pmatrix} \begin{pmatrix}A_{11}&A_{12}\\A_{21}&A_{22}\end{pmatrix} \begin{pmatrix}b_1\\b_2\end{pmatrix} \\ &= \left[ \begin{pmatrix}A_{11}&A_{12}\\A_{21}&A_{22}\end{pmatrix} \begin{pmatrix}b_1\\b_2\end{pmatrix} \right]^{\mathrm T} \begin{pmatrix}a_1\\a_2\end{pmatrix} \\ &\Rightarrow \quad \mathbf b^* = \left[ \begin{pmatrix}A_{11}&A_{12}\\A_{21}&A_{22}\end{pmatrix} \begin{pmatrix}b_1\\b_2\end{pmatrix} \right]^{\mathrm T} \end{align}.$$
Having to take the transpose makes this a little confusing, but it should be clear that $\mathbf A$ defines a dual vector $\mathbf b^*$ for each vector $\mathbf b$.
The concept of a metric tensor is basically the same thing, but with a different notation. I could not say earlier that $\mathbf A$ maps a vector to its dual, but that it defines such a map. This is because I had to use the transpose operation. Matrices are a notation designed to express vectors $V$ and linear operators $M : V \rightarrow V$, and the notation is not flexible enough to express a linear map $V \rightarrow V^*$. The notation used for expressing metric tensors (upper/lower index notation; tensor notation; not sure if it has a better name) is more flexible. The metric is denoted $g$, and by writing it with two lower indices as $g_{\mu \nu}$ we are designating it as a rank $(0,2)$ tensor that maps $V \times V \rightarrow \mathbb R$. By giving $g_{\mu \nu}$ just one argument and leaving the other empty, we are left with a map $V \rightarrow \mathbb R$, which is the same thing as a dual vector in $V^*$. We write vectors by their components, $x^\mu$, and then $g$ defines a linear map $g : V \rightarrow V^*$ like so:
$$g : \mathbf x \mapsto \mathbf x^*, \quad x_\mu = \sum_{\nu} g_{\mu \nu} x^{\nu}.$$
The notation $x^\mu$ expresses the components of the vector $\mathbf x$ in the chosen basis of $V$, and $x_\mu$ expresses the components of the dual vector $\mathbf x^*$ in the dual basis of $V$, i.e. the corresponding basis in $V^*$. The notation is frequently heavily abused for brevity, so you may see expressions like
$$g : x^\mu \rightarrow g_{\mu \nu} x^\nu \tag{implied summation over $\nu$}$$
to mean the same thing as I said above.
You may notice the similarity with matrix multiplication:
$$(b^*)_\mu = \sum_{\nu} A_{\mu \nu} b_\nu.$$
When $g$ is expressed as a matrix as in your question, it simply maps the components $x^\mu$ to the components of its dual vector, $x_\mu$. It very much is a linear map, $g : V \rightarrow V^*$ and all the associated tools of linear analysis may be applied.
Best Answer
The confusion comes from the fact that apparently 2 concepts are involved in your question which makes the topic rather complicated. The 2 concepts are :
description of the metric tensor in coordinate dependent form (the classical way)
description of the metric tensor in coordinate free form (the modern way), which actually requires the use of differential forms.
It is so easy to write down an equation like $e_i \cdot e_j = \delta_{ij}$, and it looks so intuitive that one does not hesitate a moment of believing it, but behind there is the rather abstract theory of tangent vectors and differential forms on manifolds. In this theory the symbols $e_i$ are tangent vectors of a freely chosen point of a manifold, and these are actually written as expressions of partial derivatives and in your question they are chosen to be orthonormal. In a 2-dim. flat manifold there are for instance -- it's our choice -- 2 orthonormal tangent vectors $\frac{\partial}{\partial x}$ and $\frac{\partial}{\partial y}$ which have the (nice) property to orthonormal to their corresponding covectors ${ dx , dy}$. (Covectors are the basis of the dual space, here called cotangent space, which is defined pointwise, i.e. at each point of the manifold there is another tangent space and cotangent space etc. ... ) Explicitly:
$dx(\frac{\partial}{\partial x})=1$ and $dy(\frac{\partial}{\partial y})=1$ whereas $ dy(\frac{\partial}{\partial x})=0$ and $dx(\frac{\partial}{\partial y})=0$.
Now we define what is meant by $\cdot$ the product between tangent vectors. For this we need the metric tensor $g$ which is a symmetrical tensor $e_i \cdot e_j := g(e_i, e_j)$. So if our basis is chosen to be orthonormal, then actually we get : $e_i \cdot e_j = g(e_i, e_j)=\delta_{ij}$. We will work out that a bit more. Our tensor $g$ actually is in the formalism of differential forms:
$g = dx \otimes dx + dy \otimes dy$
If we want to know its components we have evaluate it on the basis vectors (remember $dx(\frac{\partial}{\partial x})=1$ and $dy(\frac{\partial}{\partial y})=1$ whereas $ dy(\frac{\partial}{\partial x})=0$ and $dx(\frac{\partial}{\partial y})=0$. ):
$ e_x \cdot e_x = g(\frac{\partial}{\partial x}, \frac{\partial}{\partial x})= dx \otimes dx ( \frac{\partial}{\partial x}, \frac{ \partial}{\partial x} ) + dy \otimes dy( \frac{\partial}{\partial x}, \frac{ \partial}{\partial x} ) = g_{xx} = 1+0= 1.$
$ e_x \cdot e_y = g(\frac{\partial}{\partial x}, \frac{\partial}{\partial y})= dx \otimes dx ( \frac{\partial}{\partial x}, \frac{ \partial}{\partial y} ) + dy \otimes dy( \frac{\partial}{\partial x}, \frac{ \partial}{\partial y} ) = g_{xy} = 0 + 0 =0.$
$ e_y \cdot e_x = g(\frac{\partial}{\partial y}, \frac{\partial}{\partial x})= dx \otimes dx ( \frac{\partial}{\partial y}, \frac{ \partial}{\partial x} ) + dy \otimes dy( \frac{\partial}{\partial y}, \frac{ \partial}{\partial x} ) = g_{yx} =0 + 0 =0.$
$ e_y \cdot e_x = g(\frac{\partial}{\partial y}, \frac{ \partial}{\partial y})= dx \otimes dx ( \frac{\partial}{\partial y}, \frac{ \partial}{\partial y} ) + dy \otimes dy( \frac{\partial}{\partial y}, \frac{ \partial}{\partial y} ) = g_{yy}= 0 + 1 =1.$
We got the desired result, the basis vector are orthonormal as required. What happens if we change the metric ? Let's go to polar coordinates $(r,\phi)$. (Remember $(x,y) =(r cos\phi, r sin\phi)$, the derivatives below have to be carried out using this definition) With these coordinates we can construct the following tangent vectors $\left(\frac{\partial}{\partial r}, \frac{\partial}{\partial \phi}\right)$. The corresponding covectors are $(dr, d\phi)$:
The metric in polar coordinates looks like this: $g = dr \otimes dr + r^2 d\phi \otimes d\phi$
$g_{rr}= g(\frac{\partial}{\partial r}, \frac{ \partial}{\partial r})= dr \otimes dr ( \frac{\partial}{\partial r}, \frac{ \partial}{\partial r} ) + r^2 d\phi \otimes d\phi( \frac{\partial}{\partial r}, \frac{ \partial}{\partial r} ) = 1 + 0 =1. $
$g_{r\phi}= g(\frac{\partial}{\partial r}, \frac{ \partial}{\partial \phi})= dr \otimes dr ( \frac{\partial}{\partial r}, \frac{ \partial}{\partial \phi} ) + r^2 d\phi \otimes d\phi( \frac{\partial}{\partial r}, \frac{ \partial}{\partial \phi} ) = 0 + 0 =0.$
If $r$ and $\phi$ in the tangent vectors are swapped, the result is also zero: $g_{\phi r}=0$.
$g_{rr}= g(\frac{\partial}{\partial \phi}, \frac{ \partial}{\partial \phi})= dr \otimes dr ( \frac{\partial}{\partial \phi}, \frac{ \partial}{\partial \phi} ) + r^2 d\phi \otimes d\phi( \frac{\partial}{\partial \phi}, \frac{\partial}{\partial \phi} ) = 0 + r^2 =r^2$.
We actually find that our chosen tangent vectors are normal to each other, but not orthonormal. That's okay. That is our choice. The base system does not need to be orthonormal. We can actually easily fix the problem by choosing $e_\phi = \frac{1}{r}\frac{\partial}{\partial \phi}$. But there is a little caveat. Up to now our covectors (the dual vectors of the our tangent vectors) were total differentials. That is no longer possible for the new choice of coordinates. The covector of $e_\phi = \frac{1}{r}\frac{\partial}{\partial \phi}$ is $r d\phi$ which cannot longer be represented by a total differential. Such bases are called anholonom. They are extremely practical for computations, but kind of unnatural. Nevertheless in the modern formalism of differential forms you find them everywhere.
Finally, if you apply a coordinate transformation, the components of the metric tensor $g(e_i,e_j)$ transform according to the rule
$g(e'_i,e'_j) = \frac{\partial x^k}{\partial x'^i} \frac{\partial x^l}{\partial x'^j} g(e_k,e_l)$. The summation is carried out over double appearing indices.
Transformation from polar (unprimed) coordinates to cartesian (primed) coordinates: First we know from our computations above (we'll use the holonom coordinates $(r,\phi)$): $g_{rr}=1$, $g_{r\phi}=0$, and $g_{\phi\phi}=r^2$. With this in mind we set up the transformation equations:
$g_{xx} = \frac{\partial r}{\partial x} \frac{\partial r}{\partial x} g_{rr} + 2 \frac{\partial r}{\partial x} \frac{\partial \phi}{\partial x} g_{r\phi} + \frac{\partial \phi}{\partial x} \frac{\partial \phi}{\partial x} g_{\phi\phi} = cos^2\phi g_{rr} + 0+ \frac{(-sin\phi)^2}{r^2} g_{\phi\phi} = cos^2\phi + sin^2\phi =1. $
Remember, the metric tensor is symmetric, so we put together the 2 mixed terms into one and also realise that as $g_{r\phi}= g_{\phi r} =0$, we can forget the mixed terms altogether.
$g_{xy} = \frac{\partial r}{\partial x} \frac{\partial r}{\partial y} g_{rr} + 2 \frac{\partial r}{\partial x} \frac{\partial \phi}{\partial y} g_{r\phi} + \frac{\partial \phi}{\partial x} \frac{\partial \phi}{\partial y} g_{\phi\phi} = cos\phi sin\phi g_{rr} + 0 + \frac{cos\phi}{r} \frac{-sin\phi}{r} g_{\phi\phi} = cos \phi sin\phi - cos\phi sin\phi =0. $
$g_{xx} = \frac{\partial r}{\partial y} \frac{\partial r}{\partial y} g_{rr} + 2 \frac{\partial r}{\partial y} \frac{\partial \phi}{\partial y} g_{r\phi} + \frac{\partial \phi}{\partial y} \frac{\partial \phi}{\partial y} g_{\phi\phi} = sin^2\phi g_{rr} + \frac{cos\phi}{r} \frac{cos\phi}{r} g_{\phi\phi} = sin^2\phi + cos^2\phi =1. $
We can confirm that the formula for the transformation of the metric tensor in case of the coordinate transformation from polar to cartesian coordinates works correctly.
Actually, one can also do this with anholonom coordinates, may be there is a slight change in the transformation law, but a priori it should also work out. I hope this helps, but may be it would be necessary to learn something more about differential forms to make this answer even clearer.