What is the smooth structure of an embedded submanifold?

Here is a quotation from Chapter 5 in “Introduction to smooth manifolds” by J. Lee.

Suppose $M$ is a smooth manifold with or without boundary. An embedded submanifold of $M$ is a subset $S subseteq M$ that is a manifold (without boundary) in the subspace, endowed with a smooth structure with resect to which the inclusion map $Sto M$ is a smooth embedding.

My questions are the following:

  • What is the topology on $S$?
  • What is the smooth structure on $S$?

In my thought, ${i^{-1}(Ucap S)mid U in mathcal{O}(M)}$ is the topology on $S$ with the topology $mathcal{O}(M)$ on $M$.

For the second question, I think $mathcal{A}_{S}:={(i^{-1}(Ucap S), phicirc i)mid (U,phi)in mathcal{A}_{M}}$ is the smooth structure on $S$ with the smooth structure $mathcal{A}_{M}$ on $M$, but it seems to be odd for me if $mathrm{dim}(S)<mathrm{dim}(M)$ because the dimension of the image under $phicirc i$ is $mathrm{dim}(M)$, which is absurd.

Is there anything wrong with the above discussion?