What is the advantage of using buttermilk in baking?
Historically, milk was accumulated in the churn until there was enough to be worth making butter. The milk would, of course, ferment. Both the butter and the watery buttermilk took the sour, fermented flavor.

Modern buttermilk is different. It is low fat milk that has been cultured and fermented. It is thicker and creamier but has a similar soured flavor. (I've been told. I've never tasted historically fermented buttermilk.)

Therefore, historical recipes are not going to be the same as modern recipes that call for buttermilk.

The "buttermilk" left in your homemade butter would not have fermented and would not be similar to historical or modern buttermilk. It does have a good amount of sugar and protein, and of course water, that would affect your recipe.

In modern recipes, buttermilk is used to lower the ph, add a tangy flavor and a creamier texture than milk. The added fat is not usually a factor. Creamy buttermilk can be made with skim milk.

As dlb pointed out in a comment, the creaminess and acid allows chemically risen baked goods to be fluffier with the same liquid and fat content as regular milk.