The correct option is D in
Option D: 'In' is a preposition that means 'to be enclosed inside something', or 'to be surrounded by something'. It is relevant to this sentence, as the person, (Mrs. Gupta's son) works inside the factory.
Option C: 'At' also refers to a place, but it does not complete the sentence in meaning.
In this sentence, 'in' is preferred to 'at', because 'in' means that the person is physically inside a building, or a place, like a factory. Since the sentence describes a person working in a place, option D is correct.
'At' is used when the person may or may not be inside the factory. This describes a specific situation, for e.g. 'I am at the factory right now.'
Hence option C is incorrect.
Option A: 'Upon' is a formal usage of 'on'. It means 'on something'. It
is used in many abstract contexts, like 'to depend upon something'. This
meaning isn't relevant here, hence A is incorrect.
Option B:
Similarly, 'on' means 'to be attached to the top of a surface'. This
meaning is not relevant here, hence B is incorrect.