If I understand what you are asking, you would place the code (the second part you listed in the first post) inside of the functions file.
DO NOT use the open or close php portion ( <?php or ?> )
After the function exists, it may be that yoast adds a section where you can change this easily, although I am not sure as I have never used the plugin or that function.
Any time I edit php code directly, I usually try to use an editor like edit plus (since it automatically creates a .bak of the fil when you save it) and it preserves line numbers. I will often also keep notes on the line numbers I added, and if something goes wrong you can easily get the file back to where it was.
This also helps you for future functions editing etc, since you will have notes ion what worked on previous sites.
Rick
Universal4
To clarify,
you would start with
if and end with
}
Code:
if ( function_exists('yoast_breadcrumb') ) {
yoast_breadcrumb('<p id="breadcrumbs">','</p>');
}