<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def add_nodes(self, node_name_list, dataframe=False):
 """ Add new nodes to the network :param node_name_list: list of node names, e.g. ['a', 'b', 'c'] :param dataframe: If True, return a pandas dataframe instead of a dict. :return: A dict mapping names to SUIDs for the newly-created nodes. """

        res = self.session.post(self.__url + 'nodes', data=json.dumps(node_name_list), headers=HEADERS)
        check_response(res)
        nodes = res.json()
        if dataframe:
            return pd.DataFrame(nodes).set_index(['SUID'])
        else:
            return {node['name']: node['SUID'] for node in nodes}