Skin cancer is one of the most prominent types of cancer, and prompt intervention in its detection can lead to faster treatment. In the absence of timely intervention, its consequences can prove fatal. The identification of this cancer is conventionally done by a biopsy, wherein a segment of the afflicted tissue undergoes scrutiny to unveil the presence of malignant cells. Our aim is to discern and delineate the existence of cancerous cells within tissues, differentiating them from ordinary skin ailments that may mimic the appearance of malignancy to the naked eye. In this paper, the 2D Fourier transform has been applied to the input data before passing them to a convolution neural network for the classification of benign and malignant skin cancer images. 2D Fourier transform transforms the spatial information in the image into the frequency domain. The Fourier transform can reveal patterns and features in images that may not be immediately apparent in the spatial domain. Thus, the proposed model can reveal the distinguishing features present in the spatial and frequency domain. It was observed that our model demonstrates an 83% accuracy upon rigorous training, establishing its robust performance. The proposed method has distinguished the melanoma and benign skin lesion images with Area under the Curve (AUC) value of 0.93. This demonstrates the effectiveness of utilising spatial and frequency domain features for skin lesion categorisation.