Burkina Faso's government says it has thwarted an attempted coup against President Ibrahim Traore, accusing former transitional president Paul-Henri Sandaogo Damiba of masterminding the plot.