tranferring from android to iphone 6plus ... why am i only getting a 4 digit code?

instead of 6 or 10 digit code
Hello and welcome to iMore. Apple passcodes used to be only 4 digits until a couple of years ago when they gave us the possibility of setting up a 6 digit code. In order change to a 6 digit code, you'll need to know the current passcode.

Settings>Touch ID & Passcode>Enter existing Passcode>Change Passcode

Here's a link to Apple's Support Page about using Passcodes.
Because your Android device is only sending a 4 digit code to the iOS device?
When setting up an iPhone for the first time, you have the option of setting a 4 digit, 6 digit or alphanumeric pass phrase to unlock your iPhone. It is up to you what you choose.

Original thread: https://forums.imore.com/threads/tranferring-from-android-to-iphone-6plus-why-am-i-only-getting-a-4-digit-code.416844/