I recently installed LyX 2.0.1 (2011-08-31). I have the option to display the LaTeX source. I have tried to modify this source (in the LyX tab) in order to get some changes in the LyX file and the pdf output but I couldn't. I want to modify the LaTeX source directly in LyX because sometimes LyX doesn't align the tables as I want or the spaces between the lines or even the list are not in the format I want. How can I do that?
If you want to edit the LaTeX source, then LyX is the wrong tool. Use one of the LaTeX editors, e.g. TeXworks, TeXmaker, aso. LyX can only edit it's own file format which of course can have some part of LaTeX code, called ERT (Evil Red Text), but that is also part of the LyX file.
You can use CTRL + L to insert latex code anywhere. That is especially useful for mathematical equations, where auto-completion works. For example, you don't have to type \alpha, you type \a, and see many suggestions for auto-complete. To delete anything, you can uses Lyx main window.
It works neat with math, but it probably does not much sense to use it for text editing. Because for usual text you will see chunks of latex code, not WYSIWYG.
Suppose you want to modify a formula which was entered in lyx. One possibility is to display the latex source for the formula, copy it, and paste it in some latex editor. You can then modify it with the latex editor, copy it, and paste it back in the lyx editor in math-mode.
It might seem to be a dirty hack, but if you edit the lyx source file directly, the changes will be reflected in PDF (I think they won't be persistent though).