okay an isometry is a function that preserves the metric. So you have two riemannian manifolds M and N and hence given two metrics g_M and g_N.
A metric is a tensor that takes two tangent vectors as input. The way we map tangent vectors from the tangent bundle of M to the tangent bundle of N is by the differential df.
so you see that the metric is preserved if as you say:
<u,v>_p = <df_p(u),df_p(v)>_f(p) (for all p and for all u,v in T_p(M)?)
because:
<u,v>_p = g_M(u,v)(p) (i added a (p) because you have to evaluate at p in M)
<df_p(u),df_p(v)>_f(p) = g_N(df_p(u),df_p(v))(f(p))
so you need to calculate the differential of f at p in M, use it on two tangents then aply the metric in N, and see this gives the same as just aplying g in M to the two tangent vectors. This can be done in coordinates or without depending on the concrete exercise.
You are right that the metric in euclidean space just corresponds to the identity matrix, (in coordinates), but that does not give you that any function f is an isometry, you can easily see that in R^2, if we set f(x)=x^2 then whe don't have: ||x-y|| = ||f(x)-f(y)|| for all x,y in R^2, which like what you need to prove for a manifold, but because only the tangent space has a metric it is a bit more complicated.
hope this explain the general case.
Now for your more concrete example. Let's look at R^2 with the standard basis e_1,e_2, let's look at the linear function defined on the basis by
f(e_1)=e_2, f(e_2) = e_1 extend by linearity to all R^2.
This function is clearly an isometry because it only flip the coordinate system, I know that the metric actually works on the tangent space at a point in R^2, but because R^2 is so "nice" we can identify T_pM with R^2 (if you don't see this don't worry, maybe if you understand the rest you can ask about this i will explain) so that's why i can say it is an isometry, just by looking on what the function does on R^2, but in general for a manifold it depends on the differential of f.
But let's us try to show it in your notation of a riemannian manifold. So let M be the manifold R^2 and N the same namely R^2 (i know i said that that you need to check ||x-y||=||f(x)-f(y)||) in R^2, but because we look at R^2 as a manifold now, we need to be a bit carefull (as said above), the metric now works on the tangent space, so I will try to be careful and only use the metric on tangent. As i said above let's take two tangent vectors v,u to a point p in R^2=M. These are as you say just directional derivatives that is ve can write
v = v_1 \partial_1(p) + v_2 \partial_2(p), \partial_i(p) = \frac{\partial}{\partial x_i}|_p
u = u_1 \partial_1(p) + u_2 \partial_2(p)
so we see that
g_M(v,u)_p = g(v_1 \partial_1(p) + v_2 \partial_2(p),u_1 \partial_1(p) + u_2 \partial_2(p))
remember we have (for R^2)
g_M = g_N = g_{ij} dx^i \otimes dx^j = \delta_{ij} dx^i \otimes dx^j einstein summation assumed.
so we get:
g_M(v,u)_p = \delta_{ij} dx^i(v_1 \partial_1(p) + v_2 \partial_2(p)) \otimes dx^j(u_1 \partial_1(p) + u_2 \partial_2(p)) = v_1 u_1 + v_2 u_2
this is actually just the usual inner product, you see. Remeber that dx^i is defined by dx^i(\partial_j) = \delta^i_j (maybe I write to much but don't at what level you are, so just tell me if you know stuff I said, then I can leave it out in the next post, if another post is needed)
So know we need to calculate the differential df_p(v). To do this we need some curve \gamma(t) such that \gamma(0) = p, \gamma'(0) = v. It is not hard to see that such a curve could be
\gamma(t) = (v_1 e_1 + v_2 e_2)t + p
I said not hard to see, hate when people do this so let's check. \gamma'(0)
works on differential functions from M to R (and thus need to be evaluated on such), so let h be such a function and p = (p_1,p_2)
\gamma'(0)h = \frac{\partial}{\partial t}(h \circ\gamma(t))|_{t=0} = <br />
\frac{\partial}{\partial t}(h(v_1 t+p_1, v_2 t+p_2 )) |_{t=0} = (\partial_1h)(\frac{\partial(v_1 t+p_1)}{\partial t}) + (\partial_2h)(\frac{\partial(v_2 t+p_2)}{\partial t})|_{t=0} =
<br />
(\partial_1h)(v_1)+ (\partial_2h)(v_2)|_{t=0} = (v_1\partial_1+ v_2\partial_2)h|_{t=0}=<br />
(v_1\partial_1+ v_2\partial_2)h<br />
this is for all h so
\gamma'(0)= v_1\partial_1+ v_2\partial_2
so i was right :-). Now we got our curve, let's get to df_p(v), this is defined as
df_p(v) = df_p(\gamma'(0)) = \frac{\partial}{\partial t}(f \circ \gamma(t))|_{t=0} = \frac{\partial}{\partial t}(f((v_1 e_1 + v_2 e_2)t))|_{t=0}=<br />
\frac{\partial}{\partial t}((v_1 e_2 + v_2 e_1)t)|_{t=0} = v_1 e_2 + v_2 e_1
the same thing happens for u so
df_p(u) = u_1 e_2 + u_2 e_1 of cause to see this you need to find a simelar curve that fulfills \gamma(0) = p, \gamma'(0) = u
we are know ready to evaulate
g_N(df_p(v),df_p(u))_p = g_N(v_1 e_2 + v_2 e_1,u_1 e_2 + u_2 e_1)_p
like before this is just the usual inner product (now on N, but N=R^2) so
g_N(df_p(v),df_p(u))_p = v_1 u_1 + v_2 u_2 = v_2 u_2 + v_1 u_1 = g_M(v,u)_p
you see that in this case, what p i chose didn't play any role so this is for all p in M,
so we are done, I think i did it in a so general way that M and N could have been any manifolds, the onyl thing i used was that it was easy to find curves in R^2, you need to make a more general curve maybe only demanding \gamma(0) = p, \gamma'(0) = u, not even writing an explicit form of \gamma, this depend on your problem.
Hope this helps, if you can't generalize it to your problem, then post your problem and your attempt, I will try to help you further.