Actually, the screen stripes while loading from tape first occurred on the ZX-81 - Where they were a result of Sinclair's typical savvy nature - the display and the "EAR IN/MIC OUT" had to share a pin on the ULA and thus made the (whole) screen flicker in stripes during tape loading and saving. This actually proved useful as a visual clue the computer still did something and also the stripe width allowed a bit of visual feedback on how well the computer "could hear" the tape.
Thus the Spectrum got the same mechanism, this time actually intentional by code in the tape loading and saving routine that quickly changes the border colour and thus creates the loading stripes. By only changing the border colour, this also added the luxury of having a usable central screen display during loading that could display type and name of a tape header block just read.
The border stripe width is a direct indication of the current bit rate received from the tape - the narrower the stripes, the higher the bit rate. Thick red and cyan bands indicated a "wait for header" condition, and thin yellow and blue stripes mean the computer is receiving a header or data block.
With custom load routines, the border flicker could actually be controlled during the loading - Some games simply changed part of the screen area in sync with the border colour change - This could display nice things like rounded edges on the loading screen.
Custom loaders could also change the load order for load screens from its normal, linear fashion towards something more interesting - There were some famous loaders like MadLoad that loaded screens in square chunks, following some made-up patterns on the screen.
Other custom program loaders displayed a rainbow border during loading by modifying the colour selection from the standard red/cyan/blue/yellow scheme to more colours.
Doing fancy things with the border colour outside a custom program loader is actually a bit simpler - You don't have to satisfy both the loading and the border effect routine with adequate timing and can concentrate on the border only. By counting the time between vertical retraces and switching the border colours with exact timing, you can, for example, extend colours from the main screen area into the border. Aquaplane was a game known for this effect, it extended the horizon and sea displayed into the border colour, imitating a higher screen resolution than what actually was there. (Although I found the game rather boring apart from this effect)