On the surface, whales and fish share many things: use of aquatic environments, they are vertebrates and have morphological adaptions that facilitate locomotion in water. The latter is described in detail here:
The repeated invasion of aquatic and marine environments by tetrapods over the last 250 million years has resulted in a host of convergent morphological adaptations that facilitate life in water (Kelley and Pyenson, 2015). Among these adaptations are the evolution of a fusiform body shape, flattened control surfaces and sickle-shaped caudal fin to achieve high performance locomotion (Fish et al., 2008). These morphological adaptations are functionally analogous among swimming animals such as thunniform fish, lamnid sharks, cetaceans and the extinct ichthyosaurs(https://www.ncbi.nlm.nih.gov/pmc/articles/PMC8317509/).
But there are many differences.
Perhaps most strikingly different between the two is the manner in which they exchanges gases such as oxygen. With whales being mammals, they have lungs. The lungs do not have a direct interface with water and they are located in the chest. Fish on the other hand have gills. These gills exchange gases (oxygen, carbon dioxide) that are in the water.
Other notable differences include whales nursing their young as opposed to fish who typically lay eggs. Whales can have hair (for sensory use) while fish do not.