Symptomatic brain metastases or any leptomeningeal metastasis that is symptomatic and/or requires treatment. Subjects with brain metastases are eligible if these have been locally treated (surgery, radiotherapy). There must also be no requirement for immunosuppressive doses of systemic corticosteroids (> mg/day prednisone equivalent) for at least weeks before the first dose of study treatment Prior treated brain or meningeal metastases must be without evidence of progression (confirmed by MRI) for at least weeks and off immunosuppressive doses of systemic steroids (greater than mg/day prednisone or equivalent) for at least weeks before study drug administration Patients are excluded if they have active brain metastases or leptomeningeal metastases; subjects with brain metastases are eligible if metastases have been treated and there is no magnetic resonance imaging (MRI) evidence of progression for [lowest minimum is weeks or more] after treatment is complete and within days prior to the first dose of nivolumab administration; there must also be no requirement for immunosuppressive doses of systemic corticosteroids (> mg/day prednisone equivalents) for at least weeks prior to study drug administration Subjects with brain metastases are eligible if metastases have been treated and there is no magnetic resonance imaging (MRI) evidence of disease for weeks after treatment is complete and within days prior to the first dose of nivolumab. Subjects with asymptomatic brain metastases are eligible, though if treated with radiation or surgery the above criteria apply regarding a -day washout and MRI to assess for progression after weeks. Patients are excluded if they have active brain metastases or leptomeningeal metastases; subjects with brain metastases are eligible if metastases have been treated and there is no magnetic resonance imaging (MRI) evidence of progression for weeks or more after treatment is complete and within days prior to the first dose of nivolumab administration; there must also be no requirement for immunosuppressive doses of systemic corticosteroids (> mg/day prednisone equivalents) for at least weeks prior to study drug administration Patients with melanoma brain metastases are allowed; subjects with brain metastases are eligible if (a) metastases have been treated and there is no magnetic resonance imaging (MRI) evidence of progression for weeks after treatment is complete and within days of the first dose of nivolumab administration; or (b) if they are untreated but asymptomatic or c) if they are untreated and symptomatic but symptoms are controlled on stable or decreasing doses of steroids for days prior to drug administration; patients are excluded if they require high doses of systemic corticosteroids (> mg equivalent of dexamethasone) to control central nervous system (CNS) symptoms Prior treated brain metastases are allowed; however, prior treated brain metastases must be without magnetic resonance imaging (MRI) evidence of progression for at least weeks and off systemic steroids for at least weeks before study drug administration Prior treated brain or meningeal metastases must be without MRI evidence of progression for at least weeks and off systemic steroids for at least weeks prior to screening/baseline. Patients are excluded if they have active brain metastases or leptomeningeal metastases; subjects with brain metastases are eligible if metastases have been treated and there is no magnetic resonance imaging (MRI) evidence of progression for at least weeks after treatment is complete and within days prior to the first dose of nivolumab administration; there must also be no requirement for immunosuppressive doses of systemic corticosteroids (> mg/day prednisone equivalents) for at least weeks prior to study drug administration Patients are excluded if they have active brain metastases or leptomeningeal metastases; subjects with brain metastases are eligible if metastases have been treated and there is no magnetic resonance imaging (MRI) evidence of progression for weeks of more after treatment is complete and within days prior to the first dose of nivolumab administration; there must also be no requirement for immunosuppressive doses of systemic corticosteroids (> mg/day prednisone equivalents) for at least weeks prior to study drug administration Active brain metastases or leptomeningeal metastases. Subjects with brain metastases are eligible if metastases have been treated and there is no magnetic resonance imaging (MRI) evidence of progression for weeks or more after treatment is complete and within days prior to the first dose of nivolumab administration. There must also be no requirement for immunosuppressive doses of systemic corticosteroids (> mg/day prednisone equivalents) for at least weeks prior to study drug administration. There must be no requirement for immunosuppressive doses of systemic corticosteroids (> mg/day prednisone equivalents) for at least weeks prior to study drug administration Active central nervous system (CNS) metastases. Subjects with brain metastases are eligible if metastases have been treated and there is no magnetic resonance imaging (MRI) evidence of progression for (lowest minimum is weeks or more) after treatment is complete and within days prior to the first dose of nivolumab administration. There must also be no requirement for immunosuppressive doses of systemic corticosteroids (> mg/day prednisone equivalents) for at least weeks prior to study drug administration. Active brain metastasis or leptomeningeal disease; patients with known brain metastases are allowed if metastases have been treated and there is no magnetic resonance imaging (MRI) evidence of progression for at least weeks after treatment is complete and within days prior to the first dose of nivolumab administration; there must also be no requirement for immunosuppressive doses of systemic corticosteroids (> mg/day prednisone equivalents) for at least weeks prior to study drug administration Patients with known brain metastases or leptomeningeal metastases are excluded unless the following conditions are met:\r\n* Metastases have been treated and there is no magnetic resonance imaging (MRI) evidence of progression for at least weeks after treatment is complete (must be confirmed within days prior to the first dose of nivolumab administration) \r\n* There must also be no requirement for immunosuppressive doses of systemic corticosteroids (> mg/day prednisone equivalents) for at least weeks prior to study drug administration Prior treated brain or meningeal metastases must be without magnetic resonance imaging (MRI) evidence of progression for at least weeks and off immunosuppressive doses of systemic steroids (> mg/day prednisone or equivalent) for at least weeks before study drug administration Prior treated brain or meningeal metastases must be without magnetic resonance imaging (MRI) evidence of progression for at least weeks and off immunosuppressive doses of systemic steroids (> mg/day prednisone or equivalent) for at least weeks before study drug administration\r\n* For the current amendment , up to ten patients may be included in cohort that have four or fewer untreated brain metastases, with no lesion larger than cm, and no evidence of cerebral edema requiring steroids Subjects with previously treated brain metastasis who are free of central nervous system (CNS) symptoms and are >= days from treatment of brain metastasis are eligible; there must also be no requirement for immunosuppressive doses of systemic corticosteroids (> mg/day prednisone equivalents) for at least weeks prior to study drug administration Prior treated brain or meningeal metastases must be without magnetic resonance imaging (MRI) evidence of progression for at least weeks and off immunosuppressive doses of systemic steroids (> mg/day prednisone or equivalent) for at least weeks before study drug administration Patients are excluded if they have active brain metastases or leptomeningeal metastases; subjects with brain metastases are eligible if metastases have been treated and there is no magnetic resonance imaging (MRI) evidence of progression for (lowest minimum is weeks or more) after treatment is complete and within days prior to the first dose of nivolumab administration; there must also be no requirement for immunosuppressive doses of systemic corticosteroids (> mg/day prednisone equivalents) for at least weeks prior to study drug administration Patients are excluded if they have active brain metastases or leptomeningeal metastases; subjects with brain metastases are eligible if metastases have been treated and there is no magnetic resonance imaging (MRI) evidence of progression for at least months after treatment is complete and within days prior to the first dose of nivolumab and bevacizumab administration; there must also be no requirement for immunosuppressive doses of systemic corticosteroids (> mg/day prednisone equivalents) for at least weeks prior to study drug administration Known brain metastases or leptomeningeal metastases; NOTE: symptomatic, and/or if they require immunosuppressive doses of corticosteroids (e.g. > mg/day prednisone or equivalents) for at least weeks prior to study drug administration; patients with treated brain metastases who are deemed clinically stable and without radiological progression on positron emission tomography (PET), MRI or computed tomography (CT) scan performed =< weeks of study entry, are not excluded; NOTE: primary nasopharyngeal cancers that directly invade the skull base and extend into the infratemporal fossa (e) are not regarded as brain metastases and are not excluded Brain metastases are allowed if they have been adequately treated with radiotherapy or surgery and have been stable for at least three months prior to registration; eligible subjects should be neurologically asymptomatic; there is no magnetic resonance imaging (MRI) evidence of progression for a minimum of weeks after treatment is complete and within days prior to the first dose of nivolumab administration; there must also be no requirement for immunosuppressive doses of systemic corticosteroids (> mg/day prednisone equivalents) for at least weeks prior to study drug administration Active brain metastases or leptomeningeal metastases; subjects with brain metastases are eligible if these have been treated and there is no magnetic resonance imaging (MRI) evidence of progression for at least weeks after treatment is complete and within days prior to first dose of study drug administration; there must also be no requirement for immunosuppressive doses of systemic corticosteroids (> mg/day prednisone equivalent) for at least weeks prior to study drug administration Patients are excluded if they have active brain metastases or leptomeningeal metastases; subjects with brain metastases are eligible if metastases have been treated and there is no magnetic resonance imaging (MRI) evidence of progression for (lowest minimum is weeks or more) after treatment is complete and within days prior to the first dose of nivolumab administration; there must also be no requirement for immunosuppressive doses of systemic corticosteroids (> mg/day prednisone equivalents) for at least weeks prior to study drug administration Active brain metastases or leptomeningeal metastases; subjects with treated brain metastases are eligible if they meet all of the following criteria:\r\n* Must be at least days since craniotomy and resection, stereotactic radiosurgery, or whole brain radiotherapy\r\n* Must have no evidence of progression for at least weeks after treatment is complete and within days prior to first dose of study drug administration\r\n* Must have no requirement for immunosuppressive doses of systemic corticosteroids (> mg/day prednisone equivalents) for at least weeks prior to study drug administration Patients with active or untreated brain metastases or leptomeningeal metastases are excluded from this clinical trial; NOTE: patients with previously treated brain metastases must have stable neurologic status and magnetic resonance imaging (MRI) imaging following local therapy (surgery or radiation) for at least weeks, with no requirement for immunosuppressive doses of systemic corticosteroids (> mg/day prednisone equivalents) for at least weeks prior to study drug administration (stable low dose dexamethasone allowed at discretion of protocol chair) Has active brain metastases or leptomeningeal metastases. Participants with brain metastases are eligible if these have been treated and there is no magnetic resonance imaging (MRI) evidence of progression for at least weeks after treatment is complete and within days prior to first dose of study drug administration. There must also be no requirement for high doses of systemic corticosteroids that could result in immunosuppression (greater than [>] milligram per day [mg/day] prednisone equivalents) for at least weeks prior to study drug administration.