First of all, Dumbledore did NOT tell Harry the full truth (SHOCKER, right?).
He didn't actually see "himself holding socks" as the main part of an image:
Allie:
What did dumbledore truly see in the mirror of Erised?
J.K. Rowling:
He saw his family alive, whole and happy – Ariana, Percival and Kendra all returned to him, and Aberforth reconciled to him.
(source: J.K. Rowling Web Chat Transcript Jul 30, 2007 ) Now, whether he wears socks or not is unstated, but based on the rest of the answer, I would posit that yes, he does.
I would say that he did NOT outright lie (from a certain point of view :), and the socks answer was a way he hinted at the truth : The rest of the quote explains it:
"I see myself holding a pair of thick, woolen socks."
Harry stared.
"One can never have enough socks," said Dumbledore. "
Another Christmas has come and gone
and I didn't get a pair.
People will insist on giving me books ."
( Philosopher's Stone ) What Dumbledore wants isn't really socks .
What he wants is family - someone who will give him comfortable socks for Christmas and not co-workers or associates who will give him books.
Interestingly, we could surmise that this is what Dumbledore actually meant purely from the books, without JKR's interview quote above (as proof, edit history will show that I posted this part of the answer before I remembered about the interview :) JKR hints at the truth in two other places, and the first one is why the "Christmas" thing was important in the PS quote: JKR makes a big deal of Harry getting clothes from Mrs. Weasley: ...'
My mum.
I told her you didn't expect any presents and –
oh, no,' he groaned, 'she's made you a Weasley jumper.'
Harry had torn open the parcel to find a thick, hand-knitted sweater in emerald green and a large box of home-made fudge.
'
Every year she makes us a jumper,' said Ron, unwrapping his own, 'and mine's always maroon.'
'
That's really nice of her ,' said Harry, trying the fudge, which was very tasty.
(PS)
And this is an annual tradition she puts in in all the books.
JKR always goes on about how special it was for Harry to be treated as family by Weasleys (especially at the end of GoF).
Being given cloths for Christmas is a family tradition.
Something Dumbledore would severely miss.
Dumbledore lets on to Harry that the main reason he basically killed himself (accidentally - by putting on the cursed Resurrection Stone before Year 6), was because he longed to see his family: "When I discovered it, after all those years, buried in the abandoned home of the Gaunts – the Hallow I had craved most of all, though in my youth I had wanted it for very different reasons
– I lost my head, Harry.
I quite forgot that I was not a Horcrux, that the ring was sure to carry a curse.
I picked it up, and I put it on, and for a second
I imagined that I was about to see Ariana, and my mother, and my father , and to tell them how very, very sorry, I was...
This pretty clearly establishes what his deepest desire was, which is what the Mirror would show.
scifi.stackexchange.com/users/976/DVK-on-Ahch-To
Here's a second reason why "comfortable, warm socks" is an appropriate evasive answer for Dumbledore to give: It is consistent with his persona as the wise old headmaster.
The philosophers generally agree that appreciation of life's simple pleasures , such as warm feet, is a key aspect of the wisdom that comes with age.
scifi.stackexchange.com/users/21371/zwol
I think he didn't want talk with Harry about his family, it may be, because he didn't want to burden him with this information, since Harry was very young at the time or because Dumbledore was so deeply wounded by the events that he didn't want to talk about it with anyone.
It was probably a combination of both.
The socks were what he said in order to maneuver out of answering the question.
scifi.stackexchange.com/users/65339/Kamila
Despite the great Ms. Rowling's answer, I see more in Professor Dumbledore's.
I think there is foreshadowing symbolism in Dumbledore's assertion that he desired socks most of all.
Socks represented the familiarity of family that Dumbledore deeply regretted losing.
The complexity of the symbolism was made more explicit when Harry gave Dobby a sock to escape slavery.
The sock, in retrospect, is what Dumbledore needed to escape the slavery of everlasting guilt.
scifi.stackexchange.com/users/74184/Drew
Dumbledore answered the question just not when Harry asked him about it.
He sort of also answered it when he warned Harry about the dangers of the mirror.
He sees himself getting socks in the mirror because that is what he most desires -- since he has learned that he should not dwell on things that cannot be, like this family being whole again, etc.
The idea being that Dumbledore is wise enough to know he cannot have his family back and has reconciled that, so the mirror instead shows him with warm socks.
scifi.stackexchange.com/users/82139/bigfan
Spoiler Alert: If you did not see Crimes of Grindelwald - Do not read.
This does not belong here, but rather here , but for some inane reason, they're marked as dupes when they're clearly not.
Dumbledore does not see socks in the Mirror, he sees Grindelwald.
Now this is only at this particular point of time, and very likely changed, but at least in Canon we know at one point, Dumbledore's greatest desire was to be united with the one he truly loved - Grindelwald.
scifi.stackexchange.com/users/89771/TheAsh
In the Harry Potter books, Prof. Dumbledore doesn't fail to mention his love for socks, but he does fail to mention the  reason  for his fascination with them.  I think that when Harry asked him what Dumbledore saw in the Mirror of Erised, the truth was he saw his family: his sister, brother and mother; but he told Harry his second favorite desire instead: Holding woolen socks. What is the meaning of this fascination?
What is Dumbledore's fascination with socks?
scifi.stackexchange.com
<harry-potter><albus-dumbledore>
scifi.stackexchange.com/questions/71427
scifi.stackexchange.com/users/35307/SandyShores
What Dumbledore wants is  family, someone to give him comfortable socks for Christmas. This reflects what he most desires - his family being whole. Dumbledore regrets losing his family and the socks symbolise the profoundness of his loss and the strength of his reconciliation. Dumbledore appeciates life’s simple pleasures and doesn’t want to burden Harry with his guilt and pain and so he chooses to talk to Harry about socks instead. 
Dumbledore regrets losing his family and the socks symbolise the profoundness of his loss and the strength of his reconciliation. Additionally, Dumbledore appeciates life’s simple pleasures and doesn’t want to burden Harry with his guilt and pain and so he chooses to talk to Harry about socks instead. 