formaldehyde does not undergo aldol condensation
The essential condition for any molecule for undergoing aldol condensation is the presence of alpha hydrogen atom.
There is no alpha H atom in formaldehyde, so it can not undergo aldol condensation reaction.