A number of reasons, some technical. First, if they’re self-employed, they’re like artisans or trades people. They are not wage-labourers. Surplus value is created when workers labour longer than the hours it takes to reproduce the value equivalent to their labour-power. When a capitalists purchases labour-power and sells commodities with the value added in the labour process, they are seeking to maximise the surplus value and produce profits.
The self-employed window cleaner is likely to see themselves as a business person. This, to Marx, makes them tend to be reactionary: they want to maintain their position (on a low rung) of the middle class.
The employed window cleaner is likely to aspire to a round of their own one day. This puts them in a similar position to an artisan’s apprentice. Do they have much in common with the proletariat? Of course they do. And as with the historical example of the barbers in Barcelona (and maybe Seville for all I know, but unfortunately my only knowledge is of Barcelona), who during the Spanish Revolution were in the majority aligned with the anarchists and saw their interests as aligned with the working class, maybe window cleaners are all social revolutionaries, but technically they are not proletarian.