It's pretty easy to spot moths inside of a piano. Although there is no such thing as a moth nest, these pesky insects leave behind plenty of evidence. Casings, excrement, and other icky leftovers are fairly easy to spot with a flashlight.
If you have a grand piano, you will usually have an easier time identifying a moth infestation. Stand-up pianos have the disadvantage of numerous lateral crevices, which can make seeing the inside of them more difficult. Still, you will know if you have an infestation based on evidence like damaged felt. If you notice damage or signs of moths in your piano, you should take extermination and prevention measures.