This structure is grammatically termed as Cleft Sentence. The cleft sentences are created to emphasize different information denoted by different components of sentences. There is nothing ungrammatical or non-idiomatic with regard to its usage.
The definition of the Cleft Sentence by the dictionary.com:
a sentence in which a simpler sentence is paraphrased by being divided
into two parts, each with its own verb, in order to emphasize certain
information, especially a sentence beginning with expletive it and a
form of be followed by the information being emphasized, as
It was a mushroom that Alice ate instead of Alice ate a
mushroom.
From English Grammar Today (Cambridge Dictionary)
We use cleft sentences, especially in speaking, to connect what is
already understood to what is new to the listener. In a cleft
sentence, a single message is divided (cleft) into two clauses. This
allows us to focus on the new information.
It-clauses are the most common type of cleft clause. The information
that comes after it is emphasised for the listener. The clause which
follows the it-clause is connected using that and it contains
information that is already understood. We often omit that in
informal situations when it is the object of the verb:
A: Sharon’s car got broken into yesterday, did it?
B: No. It was Nina’s car that got broken into!
Focus (new information): it was Nina’s car.
Understood already (old information): a car got broken into
A: You’ve met my mother, haven’t you?
B: No, it was your sister (that) I met!
Focus (new information): it was your sister.
Understood already (old information): I met someone in your family
Is it August that you are going on holiday?
Focus (new information): the month August?
Understood already (old information): you are going on holiday
When a personal subject is the focus, we can use who instead of that.
We often omit who in informal situations when it is the object of the
verb:
It was my husband who (or that) you spoke to on the phone. (or It was my husband you spoke to on the phone.)
When a plural subject is the focus, we use a plural verb but It + be
remains singular:
It’s the parents who were protesting most.
We can use negative structures in the it-clause:
It wasn’t the Greek student who phoned.
Wh-cleft sentences are most often introduced by what, but we can also
use why, where, how, etc. The information in the wh-clause is
typically old or understood information, while the information in the
following clause is new and in focus:
A: I don’t know what to cook for them? I don’t know what they like.
B:What they like is smoked salmon.
Understood already (old information): we are talking about what they
like to eat
Focus (new information): they like smoked salmon.
A: This remote control isn’t working.
B: What we need to do is get new batteries for it.
Understood already (old information): there is something that we need
to do to fix the remote control.
Focus (new information): we need to buy new batteries.