from BeautifulSoup import BeautifulSoup, Tag
soup = BeautifulSoup(data)
for a in soup.findAll('a'):
    a.parent.insert(a.parent.index(a) + 1, Tag(soup, 'br'))
Поиск и замена в HTML с помощью BeautifulSoup