The problem with store-bought BBQ fuel is that they often add binders, accelerants and other things to the basic fuel in order to make it easier to manufacture/shape/pack/light/burn. Whilst the vast majority of store-bought BBQ fuels won't impart anything particularly bad into the food being cooked, the by-products (ash and partially-burnt coals) were never meant to come into contact with food.
Since the ashes of BBQ fuels were never meant to be reinjected into the food stream, their content is not regulated anywhere (that I know of). There are no safety protections in place.
Ash, in particular, is no longer 'organic' after being burnt. The heat of the fire has reduced it to mineral status. Whether there are things like heavy metals in there is anyone's guess. Putting that stuff into a compost pile won't 'help make it safe' because the bacteria/fungus in a compost pile feed primarily off organic molecules, not inorganic minerals. Nothing can turn cadmium into carbon.
Are there BBQ fuels being sold in stores that are 100% natural with no additives? Sure, but in my area you have to look hard to find them, they usually aren't cheap, and they often don't "work as well" as the ones that have been heavily bound and doped with accelerants.
If you make wise purchasing decisions in the store, you can throw as many coals into the compost pile as you like and they will act as moisture and nutrient stores, as well as habitat for microbes and fungi — all positive with no downsides. Small amounts of ash (less than a cup a week) will also be fine, and provide trace minerals that various organisms can use (without messing with the pH too much).
If you're producing more than a cup of ash a week, the typical 4-person compost pile won't be able to handle the load, and you should scatter the rest of the ashes evenly out onto fields/pastures, or under trees and bushes (assuming you don't want to use it to make lye for soap or any of a pile of other things). Treat the ash as a mineral cocktail that most plants can handle in very small doses, and you'll be fine.
Note: Since ash raises the pH of the soil onto which it is applied, it follows that plants that prefer acidic soils won't appreciate it. Avoid dusting the ground around such plants with ashes.
If you dump a pail of ashes into a single spot on a weekly basis — compost pile, base of tree, doesn't matter — I can pretty-much guarantee that you will kill everything there. I know of no plants or organisms that can survive that sort of abuse.