When I can divide and multiply in a limit by $x$ I have formulated an old question but in that case I have committed many errors in limit calculus and  I understand my doubt was not absolutely clear so I have decided to remove it (it had not answer) and now I try to formulate it better.
If I have a limit as $x$ goes to $\infty$ or $x\to 0$ I can multiply and divide by $x$ in order for instance to regain a notable limit. For instance $$\lim_{x\to 0}\frac{\sin^2{x}}{x}=\lim_{x\to 0}x\frac{\sin^2{x}}{x^2}=0$$
Now:
if I have for istance a function $f(x)$ s.t $\lim_{x\to \infty}\frac{f(x)}{x}=1$ and I have to compute $\lim_{x\to \infty}f(x)-x$, if I apply the previous argument ONLY on the term $f(x)$ I will obtain:
$\lim_{x\to \infty}x-x=0$.
$\textbf{My doubt is: }$is it allowed what i have done in the last?

Others can cover counterexamples, but here I'm focusing on the computational mechanism.
Here's what you need: assuming $\lim_{x \to a}f(x)$ and $\lim_{x \to a}g(x)$ exist (and in the case of division, assuming $\lim_{x \to a}g(x) \neq 0$) and are finite:
$$\lim_{x \to a}\left[f(x) \mathrel{\substack{+ \\- \\\cdot \\/}} g(x) \right] = \lim_{x \to a}f(x) \mathrel{\substack{+ \\- \\\cdot \\/}} \lim_{x \to a}g(x)\text{.}$$
In the first case, you can show that $$\lim_{x \to 0}\dfrac{\sin^2(x)}{x^2} = 1$$
thus this limit exists, and we also know that $$\lim_{x \to 0}x = 0$$
thus this limit exists, hence
$$\lim_{x \to 0}x \cdot \dfrac{\sin^2(x)}{x^2} = 0 \cdot 1 = 0\text{.}$$
What needs to be emphasized here is that the limits exist and are finite for the computation to work out.
Now, suppose you have $\lim_{x \to \infty}\dfrac{f(x)}{x} = 1$ and you want to compute $\lim_{x \to \infty}[f(x) - x]$.
Let's consider your proposed idea:
$$\lim_{x \to \infty}\left[x \cdot \dfrac{f(x)}{x} - x\right]\text{.}$$
What you had implicitly done was turned the $\dfrac{f(x)}{x}$ into $1$ by way of the limit, but the problem with that is that you're basically trying to boil it down to
$$\lim_{x \to \infty}x \cdot \dfrac{f(x)}{x} = \lim_{x \to \infty}x \cdot \lim_{x \to \infty}\dfrac{f(x)}{x} = \lim_{x \to \infty}x$$
which is NOT TRUE because $\lim_{x \to \infty}x$ is NOT finite.
