A sebaceous cyst is a closed sac under the skin filled with a cheese-like or oily material. It usually arises from Blocked sebaceous glands and swollen hair follicle. Firstly, consult a GP who will confirm the diagnosis mostly by just examining the cyst, and other conditions which can present with similar picture can also be ruled out like carbuncle, folliculitis and lipoma to name few. The treatment for sebaceous cyst is usually a simple surgical excision of the cyst along with its content. It is an outpatient procedure done under local anesthesia. The Doctor will numb the surrounding area of the cyst and make a small nick on the cyst to squeeze out the cyst contents. Following this he will then remove the cyst. This might leave a scar depending on the size of the cyst, but complete wide excision of the cyst will have lesser rate of recurrence. The doctor might prescribe analgesics like NSAIDs medication if you have pain following the excision and Antibiotics if the cyst content was infected. Sometimes if the cyst is small and if he is not suspecting infection then he might just give a steroid injection and reduce the swelling. You can also apply warm cloth over the cyst to help the cyst drain and heal.
Hope this helps. Feel free to ask further queries.