PRIMARY OBJECTIVE:
I. To compare recurrence-free survival (RFS) between patients with renal cell carcinoma randomly assigned to perioperative nivolumab in conjunction with radical or partial nephrectomy with patients randomized to surgery alone.
SECONDARY OBJECTIVES:
I. To evaluate for differences in recurrence-free survival associated with perioperative nivolumab compared to surgery alone among the subset of patients with clear cell histology.
II. To compare the overall survival between the two arms. III. To describe the safety and tolerability of perioperative nivolumab.
CORRELATIVE OBJECTIVES:
I. To correlate the primary tumor's expression of PD-L1 with outcome. II. To correlate the expression of PD-L1 on tumor tissue at nephrectomy and recurrence with outcome.
III. To archive images for potential central confirmation of recurrence and for future correlative work with American College of Radiology Imaging Network (ACRIN), including markers predicting outcome or response.
IV. To prospectively collect tumor and biologic specimens (e.g., serum, peripheral blood mononuclear cells \[PBMCs\]) for future correlative studies.
V. To characterize the pharmacokinetics of nivolumab and explore exposure response relationships with respect to safety and efficacy.
VI. To characterize the immunogenicity of nivolumab.
QUALITY OF LIFE OBJECTIVE:
I. To evaluate differences in change from baseline in patient-reported symptoms and toxicities among patients randomized to treatment with nivolumab compared to surgery alone.
OTHER EXPLORATORY OBJECTIVES:
I. To explore descriptively the efficacy of treatment with nivolumab in patients with non-clear cell (including unclassified) histologies.
II. To characterize the effects of nivolumab on bone metabolism and bone density.
OUTLINE: Patients are randomized to 1 of 2 treatment arms.
ARM A: Patients receive nivolumab intravenously (IV) over 30 minutes on day 1. Treatment repeats every 14 days for 2 cycles. Patients then undergo partial or radical nephrectomy 7-28 days later. Patient then receive nivolumab over 30 IV on day 1. Treatment repeats every 14 days for 6 cycles, and then every 28 days for 6 cycles in the absence of disease progression or unacceptable toxicity.
Patients enrolled after Amendment 4 receive nivolumab IV over 30 minutes on day 1. Patients then undergo partial or radical nephrectomy 7-28 days later. Patients then receive nivolumab IV over 30 minutes on day 1. Treatment repeats every 4 weeks for up to 9 cycles in the absence of disease progression or unacceptable toxicity.
ARM B: Patients undergo partial or radical nephrectomy within 8 weeks after registration followed by observation.
After completion of study treatment, patients are followed up every 3 months for 2 years, every 6 months for 3 years, and every 12 months for 5 years.
Inclusion Criteria:
* ELIGIBILITY CRITERIA FOR RANDOMIZATION:
* Patients must have a renal mass consistent with a clinical stage \>= T2Nx renal cell carcinoma (RCC) or TanyN+ RCC for which radical or partial nephrectomy is planned
* Patients must have no clinical or radiological evidence of distant metastases (M0) unless the presumed M1 disease is planned to be resected/definitively treated (e.g., thermal ablation, stereotactic radiation) at the same time or up to 12 weeks after the date of the initial procedure such that the patient is considered "no evidence of disease" (M1 NED)
* Liver, bone, or brain metastases are not permitted
* No more than 3 metastases are permitted, and all must be able to be removed or definitively treated within 12 weeks of the primary tumor resection
* If histological confirmation of RCC has not been done within 12 months prior to randomization, patient must be willing to undergo a core biopsy for this purpose if randomized to Arm A
* NOTE: This histologic confirmation can be a (1) standard of care diagnostic biopsy or (2) a research biopsy or a planned metastasectomy. Tissue must be obtained with results available prior to the neoadjuvant dose
* Patients randomized to Arm A: core tumor biopsy must have demonstrated RCC of any histology, including sarcomatoid, unclassified, or "unknown histology" (if preoperative biopsy was uninformative) with exception below for non-diagnostic biopsies
* If the biopsy performed following randomization clearly demonstrates a benign condition, oncocytoma or a different type of cancer that is not RCC, the patient is not eligible and must come off study
* A non-diagnostic biopsy is considered a good faith effort and does not need to be repeated unless deemed clinically necessary by the treating investigator
* Patient must not have any prior systemic or local anti-cancer therapy for the current RCC
* Patient must not have undergone a partial nephrectomy for the current RCC
* Patient must not have had a metastasectomy for the current RCC diagnosis unless performed to render patient NED (in addition to the planned nephrectomy) within 6 months prior to the current diagnosis
* Patient must not have received current or past antineoplastic systemic therapies for RCC: i.e., chemotherapy, hormonal therapy, immunotherapy, or standard or investigational agents for treatment of RCC
* Patient must not have received prior treatment with an anti-PD-1, anti-PD-L1, anti-PD-L2, anti-CD137, or anti-CTLA-4 antibody, or any other antibody or drug specifically targeting T-cell co-stimulation or checkpoint pathways
* Patient must be \>= 18 years of age. Because no dosing or adverse event data are currently available on the use of nivolumab therapy in patients \< 18 years of age, children are excluded from this study
* Patient must have an Eastern Cooperative Oncology Group (ECOG) performance status of 0 or 1
* Patient must not have a prior history of RCC that was treated with curative intent within the past 5 years
* Patients with a prior RCC that was treated \> 5 years before, are eligible if the current tumor is consistent with a new primary in the opinion of the treating investigator
* Patients with bilateral synchronous RCCs are eligible if they can be resected or definitively treated at the same time or within a 12 week window from time of initial nephrectomy (partial or radical) or procedure and maintain adequate residual renal function; the patient is not eligible if both kidneys are to be completely removed and subsequent hemodialysis will be required
* Permitted forms of local therapy for second tumor:
* Partial or radical nephrectomy
* If kidney tumor is =\< 3 cm: thermal ablation (e.g., radiofrequency ablation, cryoablation or stereotactic radiosurgery)
* Patients cannot have concurrent malignancies, with the following exceptions:
* Adequately treated basal cell or squamous cell skin cancer
* In situ cervical cancer
* A history of superficial Ta urothelial cancer is permitted (as long as not currently undergoing treatment) whereas T1 or greater disease is excluded if \< 3 years from diagnosis; concurrent persistent disease is not permitted
* Adequately treated stage I or II cancer from which the patient is currently in complete remission
* Any other cancer and stage from which the patient has been disease-free for at least 3 years prior to the time of randomization and as long as they are not receiving any current treatment (e.g. adjuvant or maintenance systemic or local therapy)
* Concurrent low risk prostate cancer on active surveillance
* Patient must not have active known or suspected autoimmune disease. The following autoimmune disorders are permitted: patients with vitiligo, type I diabetes mellitus, controlled/stable hypo or hyperthyroidism due to autoimmune or non-autoimmune conditions (hormone replacement is allowed), psoriasis not requiring systemic treatment, or other conditions not expected to recur
* Patient must not have any ongoing condition requiring systemic treatment with either corticosteroids (\> 10 mg daily prednisone equivalent) or other immunosuppressive medications with the exceptions outlined below; patient must not have received any treatment with other immunosuppressive agents within 14 days prior to the first dose of study drug with the following exceptions:
* Topical, ocular, intra-articular, intranasal, inhaled steroids and adrenal replacement steroid doses \> 10 mg daily prednisone or the equivalent are permitted in the absence of active autoimmune disease
* A brief (less than 3 weeks) course of corticosteroids (any amount) for prophylaxis (for example: contrast dye allergy) or for treatment of non-autoimmune conditions (for example: nausea, delayed-type hypersensitivity reaction caused by a contact allergen) is permitted
* Patient must not have uncontrolled adrenal insufficiency
* Patient must not have known evidence of chronic active liver disease or evidence of acute or chronic hepatitis B Virus (HBV) or hepatitis C (HCV); HBV and HCV testing must be completed within 8 weeks prior to randomization
* NOTE: If the patient has been treated and cured, and the HCV ribonucleic acid (RNA) is undetectable, the patient is eligible for this study
* Patient must not have any serious intercurrent illness, including ongoing or active infection requiring parenteral antibiotics
* Patient must not have known evidence of human immunodeficiency virus (HIV) infection, since the effects of nivolumab on anti-retroviral therapy have not been studied; HIV testing is only required if past or current history is suspected
* Patient must not have any known medical condition (e.g. a condition associated with uncontrolled diarrhea such as ulcerative colitis or acute diverticulitis) that, in the investigator's opinion, would increase the risk associated with study participation or interfere with the interpretation of safety results
* Patient must not have had any major surgery within 28 days prior to randomization
* Patient must not be currently enrolled in other clinical trials testing a therapeutic intervention
* Patient must not have any history of severe hypersensitivity to a monoclonal antibody
* Patient must have the ability to understand and the willingness to sign a written informed consent document
* Patients must not be pregnant or breast-feeding, as the effects of nivolumab on the developing human fetus or in the nursing infant are unknown; all patients of childbearing potential must have a blood test or urine study within 2 weeks prior to randomization to rule out pregnancy; a patient of childbearing potential is defined as any woman, regardless of sexual orientation or whether they have undergone tubal ligation, who meets the following criteria: 1) has achieved menarche at some point 2) has not undergone a hysterectomy or bilateral oophorectomy; or 3) has not been naturally postmenopausal for at least 24 consecutive months (i.e., has had menses at any time in the preceding 24 consecutive months)
* Patients must not expect to conceive or father children by using accepted and effective method(s) of contraception, as described in the informed consent form (ICF), or by abstaining from sexual intercourse for the duration of their participation in the study; patients of childbearing potential must use adequate methods to avoid pregnancy for 5 months after the last dose of nivolumab
* White blood cells \>= 2000/uL (within 8 weeks prior to randomization)
* Absolute neutrophil count (ANC) \>= 1,500/mm\^3 (within 8 weeks prior to randomization)
* Platelet count \>= 100,000/mm\^3 (within 8 weeks prior to randomization)
* Hemoglobin \>= 9.0 g/dL (within 8 weeks prior to randomization)
* Serum creatinine =\< 1.5 x upper limit of normal (ULN) or calculated creatinine clearance (CrCl) \>= 40mL/min (within 8 weeks prior to randomization)
* Total bilirubin =\< 1.5 x ULN (except subjects with Gilbert syndrome, who can have total bilirubin \< 3.0 x ULN) (within 8 weeks prior to randomization)
* Aspartate aminotransferase (AST) and alanine aminotransferase (ALT) =\< 2.5 x ULN (within 8 weeks prior to randomization)