I found a following sentence in my TOEIC training book.
For most of our investing clients, stable stocks from renowned companies are usually ideal.
My question is, Can I use "of" in this case? I mean, can "of" replace "from"?
Yes, either "of" or "from" can be used in your example. The meaning is close to identical. The variance in meaning is so slight the writer or speaker likely did not mean it with such specificity.
stable stocks from renowned companies
The connotation for "from" is source or origination. Those renowned companies issued the stocks.
stable stocks of renowned companies
The connotation for "of" is ownership. Owning the stocks of those renowned companies will give you partial ownership of those companies.
Again, the difference is slight, and what difference there is was likely not part of the point being made, which is that the firm tries to insure that their clients have high quality stocks.
As a side note, one of the things I liked about learning Spanish is that it uses the single word "de" as equivalent to both the English words "of" and "from". I.e., to them the distinction is not very important.