성함 is the formal form.
이름 is the polite form.
To ask, “What is your name?” in the formal form, use the subject particle 이 plus 어떻게 되세요?
성함이 어떻게 되세요?
For the polite form, use this:
이름이 뭐 예요?
To answer, simply use the standard form of name 이름.
제 이름은 김지니예요.