There is no difference between C2H6O and C2H5OH. Both are the same but in the latter one, 'OH' is specifically mentioned so as to convey that 'OH' together represents a single functional group i.e. alcohol. C2H6O and C2H5OH both represents the compound, Ethanol.