code: def _create_attach_records(self, ids, attributes):
          
          records = []
  
          timed = self._has_pivot_column(self.created_at()) or self._has_pivot_column(
              self.updated_at()
          )
  
          for key, value in enumerate(ids):
              records.append(self._attacher(key, value, attributes, timed))
  
          return records
docs: Create a list of records to insert into the pivot table.