Neither Bcrypt or Argon2 use SHA-256 or SHA-512 internally.
Bcrypt: is based on Blowfish cipher and has its own key setup mechanism, it's designed in the late 90s but still considered secure when properly configured (e.g., cost factor ≥12).
Argon2: uses BLAKE2b, newer cryptographic hash function, it has multiple versions: Argon2id, Argon2i, Argon2d.
Argon2id is considered best password hash function today.
You should not use SHA-256 or SHA-512 for passwords, these hash are for data integrity purposes, like signing requests, checking file integrity, or token hashing.
You can read more about argon2 and password storage