Militants from so-called Islamic State say they were behind two suicide bomb attacks in the Lebanese capital Beirut which killed at least 41 people.